Your character can have up to 8 planets.
You pet can have up to 8 planets.
The super star used can have up to 8 planets.
That's 24 (once everything is maxed out, the slots unlock with levels)
The planets are not "bound" therefore, if you switch the superstar/pet you may move the planets to the "new" superstar through the astro storage
As far as I saw there are only 8 unique planets in the current game build, therefore you can simply always swap them in and out depending on which pet/superstar you use.