Because people are sick of elites and this was one of the rare occasions when they had a change to show them the middle finger - if only by electing a different kind of elite.
Trump definitely had zero chance, if he was up against Sanders. But the Democrat party sabotaged its own primaries and rigged the ballot boxes in order to declare Hillary as the winner. As a result a lot of youth, who had supported Sanders abstained from voting in the main elections. And this is the reason why Hillary got lower than expected votes in the rust-belt region.