After Snape killed Dumbledore, Snape became one of closest to Voldemort. In the end, Voldemort killed Snape only because he wanted the allegiance of Elder Wand (and, he was mistaken about the rules). Did Voldemort ever learn that Snape was Dumbledore's guy?
Well, Harry told him in their final confrontation:
“Severus Snape wasn’t yours,” said Harry. “Snape was Dumbledore’s, Dumbledore’s from the moment you started hunting down my mother. And you never realized it, because of the thing you can’t understand. You never saw Snape cast a Patronus, did you, Riddle?”
— Deathly Hallows, chapter 36 (The Flaw in the Plan)
and goes on to explain Snape’s love for Lily, which of course gets dismissed.
It’s not clear whether Voldemort believed or accepted what Harry said. He makes a comment about how Snape’s allegiance is irrelevant (because now Snape is dead), but he’s dead before he can say anything more useful.
No. Snape had fully fooled Voldemort. Being the egomaniac that he was, he would have mentioned that he knew the truth as he killed Snape, instead he only mentioned that he was killing him to gain mastery of the Elder Wand.
The irony being that Snape told Bellatrix exactly what he had done. “You think he is mistaken? Or that I have somehow hoodwinked him? Fooled…the most accomplished Legilimens the world has ever seen?”(Half Blood Prince pg 26).
The clue comes from Snape's lessons with Harry in Occlumency, or hiding your thoughts. Basically, Snape learned how to hide his true motives from Voldemort even though he was a great mind-reader. Convincing him that he had wormed his way into Dumbledore's trust even though Snape was truly waiting for the right moment to undo Voldemort.