The UK's education secretary has said that all children from the age of four will have mandatory lessons on same-sex relationships.