why are fossil fuels fond buried under rock

They are not always under rock, but usually that is true. It probably has something to do with all the sediment deposition and tectonic plate subduction that has taken place 100 or so million years since the plant and animal life that forms the deposts died off.