If all that was true, Madara himself must have belonged to the Clan Aizen, not Clan Uchiha... Generally speaking, though, he might have been controlling some of the culprits for the war, and it's thus, generally speaking, possible to claim he was at least partly responsible for the awakening of Rinnegan. What comes to Nagato's origins, he would have had all the time in the world to find that out later with his sources.