I presumed that by using the Quantum Realm, he could travel through space and time (as Thor and Rabbit did to get to Asgard, and posing the question as to why they needed to take the Benetar with them at all?), so the when and where are sorted, but for me, the how is never answered.
How did he get the Space Stone back into the Tesseract in 1970? How did he inject the Aether into Jane Foster on Asgard? How did he get the Mind Stone back into the scepter in New York in 2012, or the Power Stone into the orb on Morag? The Time Stone is sorted, he just gives it back to the Ancient One, but the Soul Stone? Awkward moment with Red Skull and the subsequent "no returns or refunds" conversation regarding Natasha.
He doesn't seem to be carrying much equipment when he leaves, aside from a case which presumably contains the 'raw' stones.