It can. In permaculture models where you are not supplying a lot of inputs and able to cycle 100% of the manure back on grass it's great. In 20 years of running a horse farm the quality of our pasture and hay has been steadily getting better because we've been building soil.
Apply huge amounts of nitrogen fertilizer to grow corn, badly contaminating the Mississippi river and creating a dead spot in the Gulf of Mexico, feeding animals in CAFO where discarding of the manure is a problem and that's something different.
Real life systems are a little more complex than that as a cow might be grown up on scrub land and then fattened up at a CAFO for the last few months. Who knows what the long term fate of land that is cleared in the Amazon rain forest is.