XmlDocument won't allow that -- it can only support one document at a time. The example you show at the top is two documents. Either combine them into one document (with one root node), or produce them separately.
"
XML documents form a tree structure that starts at "the root" and branches to "the leaves".
XML documents must contain a root element. This element is "the parent" of all other elements.
The elements in an XML document form a document tree. The tree starts at the root and branches to the lowest level of the tree.
"
--
http://www.w3schools.com/xml/xml_tree.asp[
^]