Because you don't live in a democracy. And you don't get elected after every primary, primaries are held before election to see who is popular.
Sanders approval rating is through the roof and has been consistently over the years, easily the most popular senator across the board.
Your answer is the DNC, ain't that complicated. Sanders won the votes of the people, but the liberals and dems pushed Hillary anyway in 2016, and lost.
He was always crazy though. You just weren't paying attention then. No one remembers him going wild and calling the Thai rescue divers pedophiles to their face and all that?
The rich aren't listening, what's your genius answer?