Using XML file on Excel, and working further on it is quite simple, and we are going to use Microsoft Excel to use XML, but first you need an XML file.
This would look like this, in assumption that you use Notepad to create it:
Important note: you must save this file in an xml format.
Open Microsoft Excel, and press Open on top.
Browse to the XML file, and click on the arrow under or side of "file name", and choose XML files.
Choose the XML file.
Click on the open as XML table, and press Ok.
Just click Ok.
Click on the last cell in the table, and press TAB on your keyboard.
Keep filling the XML table with details.
In conclusion, only use the tab button on your keyboard at the last cell of the row. Everything you input must be in the XML table. You should always save it as XML if you wish to keep the format, otherwise Excel would save it as Excel worksheet.
Further reading: SQL Server Exponents How to create Excel file with PHP?