How does the earth spinning create gravity?
It doesn't. Gravity is a consequence of mass not motion.
I am not sure how this question has arisen, but spinning space stations to create artificial gravity using centripetal force has been suggested for some decades.
For example, if you are standing inside a large rotating cylinder in a low gravity environment then your natural trajectory would be tangential, but the wall of the cylinder (your floor) exerts a force that keeps you inside the cylinder. If you jumped in the air a little, the horizontal component of your inertia would cause you to collide with the wall of the cylinder (your floor) again, as if pulled down by a gravitational force.
Note that this effect is far from a perfect simulation of gravity, but it would probably help.
Gravity is caused by mass curving the fabric of spacetime. The Earth's gravity is due to the Earth's mass and nothing else.
TheEarth's spin is too slow to have any effect. It would have to be spinning very fast for relativistic effects to have any effect.
Gravity and acceleration are indistinguishable. Gravity can be simulated in a spacecraft by spinning the spacecraft. In this case gravity is simulated by the centripetal force required to move in a circle.
If the Earth wasn't spinning at all it would still have gravity.