He told Obito that he awakened it near his death... you know Madara survived right?
What are those things?
Yes but the manga showed madara awakening it as old man I think he awakend it in his prime.
When Madara said that he awakened the Rinnegan right before his death, he meant that the Rinnegan appeared before his natural life-span expired. Before his life-force ran out, he summoned the Gedo Mazou, hooked himself up to it and pumped his body with Hashirama/Gedo Mazou chakra to keep himself alive.
As long as he was connected to the Gedo Mazou, he would remain alive, although his natural life-force ran out.