Exactly. If he could bring Yahiko back to life for realreal I'm sure he would have.
I don't even think he can actually bring people back to life. Evidence seems to suggest that they bodies are just puppets. Corpses being controlled by chakra. The giant demon head seems to be able to repair the bodies if they become damaged, but doesn't actually bring them back to life.
I'm still not exactly sure which of Pains powers are from the Rinnegan at this point. It seems pretty obvious besides the shared perception thing that its also what allows him to generate the chakra waves that let him control his bodies.
Originally, I just thought that was it, and the different powers the different bodies had came from the bodies themselves. But since we now know that he just grabs a new body when one is lost and the new body gains the powers of the old one, it seems the powers of the individual bodies ALSO comes from the Rinnegan.
It's another stupid swiss army magic eye, just like the Sharingan...