First off, Itachi himself said that "You cannot cast Genjutsu on someone who uses the same eyes:"
The Rinnegan is an evolution of the Sharingan, so naturally it should be included in that same statement. But I know Mangapanda's translations weren't exactly top-notch during that time, so I got the VIZ translation. And this is what Itachi says:
~~
Second, Nagato was said to have mastered all the elements, including Yin Release. And Nidaime Mizukage, a master of Genjutsu, said that Genjutsu falls under Yin Release. So naturally I'd assume that a master of Yin Release, and thus Genjutsu, wouldn't have Genjutsu as his primary weakness (contrary to what many users say). So not only is Nagato immune to vision-based Genjutsu (see above), but he should be more than capable of countering other forms of Genjutsu too. People seem to overlook the fact that he mastered Yin Release though.
You must be registered for see images
Now obviously this isn't an absolute, as Danzo, Kakashi, and Part 1 Sasuke were all put under Genjutsu before. But notice how all of these people were inexperienced with the Sharingan (Kakashi and Sasuke), or too arrogant (Danzo). Nagato, on the other hand, had the Rinnegan for 30+ years, and we even got a glimpse of how strong his defense was against Genjutsu when the Konoha ninja tried entering Pain's mind. So he should definitely be one of those who vision-based Genjutsu is useless against. Notice how Edo Itachi, someone who has utilized Genjutsu in all of his fights, didn't even attempt any Sharingan Genjutsu against Edo Nagato.Normal vision-based genjutsu is powerless against ocular powers.
~~
Second, Nagato was said to have mastered all the elements, including Yin Release. And Nidaime Mizukage, a master of Genjutsu, said that Genjutsu falls under Yin Release. So naturally I'd assume that a master of Yin Release, and thus Genjutsu, wouldn't have Genjutsu as his primary weakness (contrary to what many users say). So not only is Nagato immune to vision-based Genjutsu (see above), but he should be more than capable of countering other forms of Genjutsu too. People seem to overlook the fact that he mastered Yin Release though.