Marks & Spencer has apologised after a transgender employee approached a 14-year-old girl in the bra section and offered to help.