>>516057471
A quick google search tells me they use Kepler's laws.
Im not going to act like i know what this crap means but to my very limited understanding the calculate mass by how gravity makes this objects move or something like that.
If an object is bigger it obviously has more gravity so rotations can vary, like on those old fountain things where you dropped coins to donate to hospitals, bigger coins spinner faster so im assuming something similar happens with celestial objects, even though they have a very big rotation around it sun they probably move a lot faster than earth.