The Trump administration argued that a federal judge couldn’t force the government to remedy the mistake.