Did he not not learn how to open portals from reading her scrolls?
Did Madara not learn his abilities from the Sage's scroll?
No and no. He learned to open portals simply by training his rinnegan. I know this because the scrolls were found in Kaguya's dimensions, so if he needed the scrolls in order to learn how to open portals then he wouldn't have been able to open the portals to get to the scrolls to begin with.
Also, it was implied during the Kaguya fight that Sasuke was attempting dimensional travel with his rinnegan when Kaguya threw him to the sand dimension, but he couldn't get it at the time.
As for Madara, he learned his abilities from the tablet, but that is because Black Zetsu specifically altered the tablet to be a quick and easy cook book for Uchihas to gain power. Black Zetsu specifically wanted one of Indra's descendants to awaken the rinnegan.
That is not the case with Kaguya's scrolls, as we do not know her to have been specifically trying to lead someone to gain power.