Education Secretary Gavin Williamson has said he is "incredibly sorry" for the distress the A-level and GCSE results row caused to students.