input: Write a function to create an XML document in Python which contains a list of items provided. The function should take a list of items as input and return a string representation of the XML document.
  
  import xml.etree.ElementTree as ET
  
  def create_xml_doc(items):
      data = ET.Element('data')
      for item in items:
          item_element = ET.SubElement(data, 'item')
          item_element.text = item
      tree = ET.ElementTree(data)
      from xml.dom import minidom
      xml_str = ET.tostring(data, 'utf-8')
      parsed_xml = minidom.parseString(xml_str)
      return parsed_xml.toprettyxml(indent="  ")
  
  assert create_xml_doc(["Item1", "Item2", "Item3"]).strip() == '<?xml version="1.0" ?><data><item>Item1</item><item>Item2</item><item>Item3</item></data>'
  assert create_xml_doc([]).strip() == '<?xml version="1.0" ?><data /></data>'
  assert create_xml_doc(["Apple", "Banana", "Cherry"]).strip() == '<?xml version="1.0" ?><data><item>Apple</item><item>Banana</item><item>Cherry</item></data>'
output: 
  def create_xml_doc(items):
      data = ET.Element('data')
      for item in items:
          item_element = ET.SubElement(data, 'item')
          item_element.text = item
      tree = ET.ElementTree(data)
      from xml.dom import minidom
      xml_str = ET.tostring(data, 'utf-8')
      parsed_xml = minidom.parseString(xml_str)
      return parsed_xml.toprettyxml(indent="  ")
  