US President Donald Trump has defended former aide Rob Porter, who has resigned after two of his ex-wives accused him of abuse.