UNM president to leave early under deal