The head of the World Trade Organization (WTO) has warned it would be chaos for companies around the world if US President Donald Trump follows through on his threats to leave the institution.