OK, well, I think that you have two choices going forward, @Zohaib1999 :
- Start messing around, and trying some stuff ... it's probably a learning thing that you might only ever really get to grips with this way 👍
- Perhaps help us all to help you a little better by adding some more information to the original question 🙂
On the latter, perhaps just edit your original question with a screen shot of the error that you got.
Plus (if you can) make a code block and include the response data from the previous step (just replace anything sensitive with garbage text) so that you can then point out which part you wish to make the XML from.
To be clear, to convert to XML you must have a root node which contains another node with the data.