Itachi's appearance in the fight between Sasuke and Danzo is an illusion. Several reasons pointing to it can be found in the manga chapters, if one looks hard enough. Firstly, Itachi coming back from the dead...now, that is not an impossibility in the Naruto world, but several characters, namely Madara Uchiha, have clearly stated Itachi is dead.
Take chapter 401, page 15 from onemanga: "he had to fight you...and die before your eyes."
Chapter 462, page 8: "that's the truth about Itachi. He died for Sasuke, and for Konoha."
Chapter 396, page 7: "but for now, we need to get Itachi's corpse, and leave immediately."
With this, we can conclude that Itachi appearing is simply an illusion. Now, if Itachi indeed was resurrected somehow, only a very few number of characters would be able to do it. For one, Chiyo, grandmother of Sasori, could if she actually wanted to, but she died long before Itachi did, because she used her resurrection technique to revive Gaara.
But also, it would be random for Chiyo to revive Itachi even if the timeline worked. Why would she do that? It's not like she has any relation to him, and she doesn't know the truth about him to begin with anyway.
The other character who would be able to revive Itachi would have been Nagato, with his Rinne Tensei technique. Nagato did indeed die after Itachi did, but as with Chiyo, Nagato had no relation with him. Nagato was able to only use his Rinne Tensei technique once, and he used it to revive all those he killed when he attacked Konoha. So, the possibility of him reviving Itachi no longer works. As it does not with Chiyo.
But, there is a point I want to make. Itachi appearing in chapter 477 might not have been under Sasuke's own free will. Remember, as Madara said earlier, Itachi implanted all of Sasuke's eye techniques into him, so maybe the result of using Amaterasu, or even the sight of one of Danzo's Sharingans, would cause Itachi to appear, as sort of a fail-safe Madara mentioned in chapter 397.