On Sept. 3, 2002, amateur astronomer Bill Yeung found an asteroid. Initially named J002E3, astronomers tracked it and found that it was in Earth orbit, which was surprising. Objects within the Earth-moon system are quickly ejected, meaning this asteroid must have been a recent capture. Spectroscopic observations revealed the "asteroid" had a signature consistent with white titanium dioxide paint NASA used to paint the Saturn V rockets. Asteroid J002E3 turned out not to be an asteroid at all but the upper S-IVB stage of Apollo 12's Saturn V from 1969.
So what happened to the rest of the spent Saturn V rocket stages?
ANALYSIS: When (Part of) Apollo 13 Reached the Moon
The Saturn V was a three-stage rocket. The first stage, the S-IC, and the second stage, the S-II, both fell away once they were spent and landed in the ocean downrange from the launch site at Cape Canaveral. On lunar missions, the third S-IVB stage stayed with the spacecraft.
After a brief stay in Earth orbit, the S-IVB fired a second time to propel the spacecraft to near escape velocity on its path to the moon. Then came the transposition, docking, and extraction phase: the command-service module separated from the S-IVB then turned around to dock with the lunar module encased within it. Once the two spacecraft were docked, they would separate from the S-IVB entirely.