I have recently written about this issue. I will say it here again so that it may be of use:
Use the existing Physics2D. Don't reinvent the wheel. There's a component called PointEffector2D, you're trying to achieve its effects manually, which will end badly if it's not implemented correctly.
Here's the manual whatfor effectors. What you want, is to have inverse squared force mode with a negative number as the force. You don't need a rigidbody on the planet but you do need a Collider2D that will be used by effector.