The United States informed the government of Niger on Friday that it agreed to its request to withdraw U.S. troops from the West African country, said three U.S. officials, a move the Biden administration had long resisted and one that will transform Washington’s counterterrorism posture in the region.