I feel like we’ve said this to OP already too, but:
…it came off that he was so popular…
However it may have come off, not enough people voted for him to win him the primary. He wasn’t that popular. For reasons mentioned elsewhere.
It’s possible some people who favored Sanders over Hillary voted for Hillary in the primary anyway fearing that she was more likely to win the primary and not wanting to chance unintentionally boosting the chances of someone other than Hillary or Sanders getting the nomination. I don’t know of any polls or anything that might have indicated that was or wasn’t the case. But that still means people didn’t vote enough for Bernie.
“Streisand effect” comes to mind, but like “sunk cost fallacy” it’s just an example of something “becoming more popular the more it fails.”