In ancient forests, there were strange trees that weren't always biodegradable because of the absence of the wood-eating bacterias and microbes.
Bacteria and fungi eat away at fallen trees, but that wasn't always the case. Bacteria had to evolve to eat wood, so hundreds of millions of years go, trees would fall at death, leaving large piles of deadwood. Forest fires of unimaginable proportions would burn the massive mounds of deadwood. And that's where most of the coal on Earth came from.
Bacteria existed, of course, but microbes that could ingest lignin and cellulose "the key wood-eaters" had yet to evolve. It's a curious mismatch. Food to eat but no eaters to eat it. And so enormous loads of wood stayed whole. "Trees would fall and not decompose back,"
Instead, trunks and branches would fall on top of each other, and the weight of all that heavy wood would eventually compress those trees into peat and then, over time, into coal. Had those bacteria been around devouring wood, they'd have broken carbon bonds, releasing carbon and oxygen into the air, but instead, the carbon stayed in the wood.