The centre of mass is not the same as the centre of gravity.

To take the simplest example, a body consisting of two point masses A and B, 1 kg each, placed 1 m apart. The centre of mass C is halfway between the two masses.

If however the body is placed in the vicinity of a point mass M Kg, the centre of gravity is found by analysing the force on each part of the object.

The force of gravity on the body above due to the mass M is

The angle this force makes with the line AB is

The centre of gravity of the body lies on the line DM. Simple trigonometry giveswhich is not equal to the distance CB in general, so the centre of gravity does not coincide with the centre of mass. Even worse, as the body moves around in the gravity field, the centre of gravity moves with in the body. The centre of gravity does not occupy a fixes osition even within the body.