Moment of Inertia of a planet

Radio Doppler measurements were taken with Viking and twenty years later with Mars Pathfinder, and in each case the axis of rotation of Mars was calculated. By combining this data the core size was constrained, because the change in axis of rotation over 20 years allowed a precession rate and from that the planet's moment of inertia to be calculated

Quoted from the the Insight mission.

The payload doing radio doppler measurement is RISE(Rotation and Interior Structure Experiment).

How can measuring the axis of rotation helps in finding moment of inertia mathematically?

If I remember $L = I \times \omega$

So if $L$ is constant then by having multiple measurements of $\omega$ one can probably solve for Inertia Matrix. But I guess they are using some precession rate equation probably. How are they doing it? What is the Maths ?