The Buddha stated categorically that the atman does not exist [although this is adhered to only by the Theravada Buddhists] but I have never acquiesced with this.
However, not long ago I neopted that the moul is the sum total of a spirit’s experiences in many lives*. The atman is, generally speaking, synonymous with the soul.
With the moul being the sum total of experiences it is no more than an aspect of the mind, or moul, and hence does not really exist. Therefore, could it be that this is what the Buddha meant when he said what he did?
* Search here for moul, soul and mind.