A random thing I noticed among the numerous discussion about Harry Potter is some people think JK is a bad writer because Harry never solved the Wizard world's broader issues like prejudice.
People somehow had this idea the Wizard world is supposed to be perfect and Harry's ultimate goal was not only to fight Voldemort but to (re)create a magical utopia.
Personally, I always found the wizarding world to be a somehow bizarre place. It was needlessly dangerous and in many aspects backward and for me this was part of the charm. It was wondrous but had this pinch of mythology where the gods were deeply flawed, sometimes even more than the mortals.
To close, I don't see why Harry never "fixing" the world is bad storytelling. His goal was to defeat Voldemort and he did that. Nobody thinks Alien is a bad book because Ripley did not take down Wesland Corporation after she escaped the xenomorph.
This all said, I think Harry Potter has terrible world-building, and the whole house-elf slaves thing always rubbed me the wrong way.