They're reincarnations. Indra and Ashura's souls aren't literally inside of them, Madara/Sasuke and Hashirama/Naruto basically have a bit of their DNA. Only I believe the retarded explanation the manga used was they have their chakra, or some shit like that.