Sean Spicer, the first White House press secretary to serve under the administration of US President Donald Trump, has stepped down after a few months in the role.