Mayor Zohran Mamdani shook the Democratic establishment by helping drive three progressive candidates to victory.