The 41-year-old’s decision to quit after less than three years in office dealt a new blow to Western governments still in shock from Britain’s vote to leave the European Union and the election of outsider Donald Trump as U.S. president.