I was just rewatching episode 426, and at 10:54, Sarutobi (the Third) called Yamato by his name. That name was assigned by Tsunade after the Third's death. How did he come to know his name?
In - universe reason : Tsunade did gave him the name Yamato but it was never implied that Anbu codename can't be reused. Maybe she used his old name and third knows it.
Out-of Universe reason : Kishimoto must have forgot it due to complex nature of story, this kind of mistake are not that uncommon in any series and anime just followed manga and kept it that way.