The UK will maintain duty-free access to its market for goods from dozens of developing countries once it has left the EU.