Nobody says that Ivermectin definitely doesn't work. What's being said is that there isn't sufficient evidence that it does work, and that until such evidence exists, people should stick to proven measures and shouldn't spread unproven claims.
Spreading unproven claims could, for example, cause people to rely on Ivermectin instead of getting vaccinated, which would be an extremely dangerous bet with almost nothing to win and almost everything to lose.