Simple really, the immunity to hazards is far more valuable than nearly everything else for certain mons. In the case of mons like Zapdos or Tornadus, the immunity to hazard is significantly better than whatever else they can use. To expand on Raptor's point, if you are running a Pokemon who's main job is simply to spam switch moves like Tapu Koko or Dragapult, then you are gonna want boots. The biggest disadvantage of those mons is that hazards will wear them down very quickly and well, Trigon help them if them click a you turn right into tank Garchomp with hazards up on the field
As for other rock weak mons, not all of them run boots as their item. The biggest example of this is Blacephalon. You are almost never gonna see clown beast run boots. It's usually gonna be specs or scarf. Weavile on the other hand, does run band from time to time. The thing about Weavile is that both sd boots and band are equally viable. Band would usually run beat up and is a common lead intended to deal as much damage as possible while sd boots is usually a revenge killer or late game cleaner. In previous gens, aside from rocks, they had other issues. For Blacephalon, it was Tyranitar. Really, if it runs into Tyranitar then its just gonna get pursuited. For Weavile, it was Mega Scizor. The thing pretty much just shits on it at every single turn and when combined with rocks, the Weavile user has a very big task in getting rid of mega metal bug, which is far easier said than done
Just a couple months after crown tundra dropped, one of the premier boots user was Moltres, the regular one, and this was because of flame body being one of the best options of dealing with the obnoxious Cinderace. However, once Cinderace was banned, it pretty much fell off the map as soccer bunny was its main target and the stuff that Moltres was supposed to deal with, Kartana and Rillaboom, almost always carry knock off which pretty much dooms it since it can't really deal with the common rockers in Landorus and Garchomp in a prolonged battle without boots. Speaking of Cinderace, it was another boots spammer and it was for the same reason as Koko, spam switch move or click a super effective move if you get the chance. Soccer bunny was so obnoxious that a lot of teams had rocky helmet Garchomp or baneful helmet Toxapex just to deal with it. If it had to run an item that isn't boots, soccer bunny wouldn't have been as obnoxious as it was
Another one that needs to be mentioned is Volcarona. In pretty much all previous generations, it was incredible hit or miss and that was partly because of stealth rock. The moth was largely do or die because if you are forced out after one rocks switchin, then it's barely gonna do anything useful anymore. Boots was a godsend for this Pokemon but it came at a heavy price, it can no longer deal with lava frog at all
The last thign I wanna mention are the common boots users rn that aren't pure switch moves, Zapdos and Tornadus, are not helpless even if they lose the thing. Trying to knock off Zapdos could be punished by a devastating paralysis, has access to roost and more importantly, doesn't really change that much. After all, Zapdos has been dealing with rocks since gen four and it has always thrived even in its presence. Tornadus on the other hand, has access to regenerator which outheals stealth rock. Boots only makes it more obnoxious than it already is but I will have to mention, this isn't all the time as Torn often runs Assault Vest. About Corviknight, the reason it doesn't run boots is because it also serves as a knock off absorber. It usually wants helmet to chip down whoever knocks it off or lefties so that it can stick around longer if its item doesn't get removed
You can also refer to this video to see just how much impact Stealth Rock has had for over a decade and why Boots is run more than the traditional items