I made a theory concerning the same problem. I believe that Itachi met with the real Madara. Madara unlocked his rinnegan so he want back to read the tablet and Itachi noticed him.
Two things lead me to this theory:
1. Itachi knows the difference between Tobi and Madara, so if he says he met with Madara, I stick to that.
2. Tobi "gave the rinnegan" to Nagato, but that could have only happened lots of years before meeting with Itachi. Unless Tobi transplanted some of those eyes in his collection and unlocked the rinnegan again, I don't see any other way how that could have been done. If it was so easy, he would have had a rinnegan army by now, right?