The main reason why raising cattle contributes to global warming is:
Cattle have microbes in their stomach that produce methane during digestion.
Methane is a potent greenhouse gas, significantly more impactful than carbon dioxide in terms of its heat-trapping ability in the atmosphere.