Mali’s prime minister and his whole government resigned on Thursday, four weeks after a massacre of some 160 Fulani herders by an ethnic vigilante group shocked the nation.