I'm looking for an ZF2 internal solution too, @Hooli. Hoping to get some answers on Twitter too: What is the best way to generate / write #XML in #ZF2? Make use of \Zend\Feed\Writer or an external class like #SimpleXML? Any known module?
Maybe one can use the Zend\Feed\Writer for these cases as a workaround but I would prefer a ZF2 module or similar.
Otherwise @Tim is right, SimpleXML is a good solution. For bigger files XMLWriter is recommended.