The earth rotates on it's axis and orbits the sun. The sun rotates on it's axis and orbits the center of the Milky Way galaxy.

Gravity is a very attractive concept