The UK government will consult extensively on the issue of Brexit in order to ensure a smooth withdrawal from the European Union, UK Prime Minister Theresa May said.