nested xml views export
The best way for creating data output from Drupal is by relying on Services it will give you XML-RPC or REST server which will be capable of outputting data in precisely the way you want. 
 I will lay out in steps:


Installing Services module
Creating an endpoint and firring up a server.Here is simple guide how to do that.
To format Service output you will need to create a simple module or rely on contributed modules.


Writing a module may seam bit tricky for a beginner so I suggest using modules like Services Views which will let you add a Service type view page or use Services Entity API or Services SearchAPI.