i think that at the end of sith they think anakin is dead, however, it wouldnt be long for them to see that he is stil alive, they knew he's name was vader as it was, so when they saw this big black dude named vader they would have made the connection.