After finishing the 7th books of Harry Potter, there is a detail that made me feel uneasy since then. Grindelwald the greatest dark lord of his time with the aid of the Elder Wand lost to Dumbledore. How the hell could this happen? Here is the description of the Elder Wand:

"So the oldest brother, who was a combative man, asked for a wand more powerful than any in existence: a wand that must always win duels for its owner, a wand worthy of a wizard who had conquered Death! "

That doesn’t make any sense at all. How can Dumbledore possibly win the man possessed the most powerful wand in the existence. I've been wondering about this for years and now I've stumbled on the answer. The Elder Wand was never in the possession of Grindelwald and therefore Dumbledore was never the true master of the Elder Wand either.
But, you may ask if that was the case how could HP win the duel with Voldemort at the end? And we know for a fact the HP was the true master of the Elder Wand since he performed a spectacular spell to restore his wand.
Yes, HP was indeed the true master of the Elder Wand in the end, but it's not because he defeated Draco Malfoy. The Elder Wand change its allegiance to Harry because Harry defeated Voldemort. Voldemort was the true master of the Elder Wand. Shocking, huh?
Have you ever recognized that if the explanation of Harry before the duel was true, the whole plot of the story came down to the random chance of Harry being kidnapped and brought to Malfoy's mansion? If that's how the story went and ended, it sounds kinda lame to me.
Back to the Elder Wand. One could only win the allegiance of the Elder Wand by defeating its previous owner. The Elder Wand, with the reputation of a powerful object, would change its alliance to only work for the wizard that bests its current wielder. Power seeks more power. This is essentially how the whole world function, wizard or wand are no exceptions.
"Gregorovitch burst into the room at the end of the passage and his lantern illuminated what looked like a workshop; wood shavings and gold gleamed in the swinging pool of light, and there on the window ledge sat perched, like a giant bird, a young man with golden hair. In the split second that the lantern's light illuminated him, Harry saw the delight upon his handsome face, then the intruder shot a Stunning Spell from his wand and jumped neatly backward out of the window with a crow of laughter."
This scene depicts that Grindelwald stole the Elder Wand from Gregorovich. The Elder Wand didn’t give Grindelwald its full potential because he acquired the wand through a cowardly action - theft. So until his death, Gregorovich was still the true master of the Elder Wand. And Voldemort is the one who killed Gregorovich, he truly overpowered Gregorovich, that win him the allegiance of the Elder Wand.
But if he's the one that has the ability to bring the Elder Wand to its true power, why couldn't he do it?

"a wand worthy of a wizard who had conquered Death!".

At this point, Voldemort's nowhere near conquering Death. 5/8 of his Horcruxes has been destroyed. He cannot perform great magic even with the Elder Wand because he's less of a wizard. Yet he's failed to realize such cruel truth due to his arrogance, he would rather blame the Wand than his own prowess. He's less powerful than he thought since his fragmented soul has been destroyed piece by piece without him realizing it.
Harry won the duel because he's truly more powerful than Voldemort. He's coming back from the dead. He possessed the resurrection stone and is still the owner of the invisibility cloak, 2 out of 3 deathly hallows. He's literally conquered Death. When Voldemort was destroyed by Harry, the Wands allegiance changed because Harry had bested its actual owner, not because Harry had bested Draco Malfoy, who was the supposed master of the Elder wand after disarming Dumbledore. The end result is still the same, but the path of the Elder wand Allegiance is different than Harry suspects.