Carbon in the soil would be what's left of anything that died in there, or any animal feces.
Carbon in the soil may possibly benefit bacteria that live in the soil, which may fix or otherwise convert nitrogen, but the plants don't use it.
However, let's imagine a dog is walking around and dies. It will rot into a gooey paste as maggots eat it, and then will liquefy into a putrid mess and eventually what's left of it will turn to dirt.
The dirt will have lots of carbon in it, which bacteria will probably use,
The dirt will have lots of minerals in it, which the plants DO use
They get their carbon from co2.