input: Write a function to create an XML document in Python that contains the given list of items as sub-elements under a root element named 'data'. The function should take a list of strings as input and output an XML document named 'data.xml'. 
  
  assert create_xml(['Item1', 'Item2', 'Item3'])
  assert create_xml(['Item4', 'Item5'])
  assert create_xml([''])
  assert create_xml(['Item6'])
output: def create_xml(items):
      from xml.etree.ElementTree import Element, SubElement, ElementTree
  
      root = Element('data')
      for item in items:
          SubElement(root, 'item').text = item
  
      tree = ElementTree(root)
      tree.write('data.xml', encoding='utf-8', xml_declaration=True)