The moon used to be apart of another solar system. In this solar system the moon was a planet itself. There was a rouge planet that was flying at such a high speed that...
When it collided with the other planet the rogue planet was destroyed but the other planet was split into peices.
A peice of the planet bounced of the moon and sent it out into space. The moon became a rogue planet itself.
It was exploring space for so long that the water froze and all life on it died. It went through our asteroid belt and created the craters that are on it. It passed through the asteroid belt and reached the goldilocks zone.
It was not traveling straight towards earth but only passing by. It got to close to earths atmosphere and earth captured it.
The moon was not big enough to escape or leave the earths atmosphere. Tht gave us the moon we know and love today.