Robert Swannell, the chairman of Marks & Spencer, is to step down after six years at the helm of the UK retail group.