How to get a XML declaration into transformation output?

I have a result transformation on an API data page. I want the xml declaration to be present in the transformation output. Even though I have added the specifics in the transformation, the declaration is still not there. How can I achieve that?

<xsl:output method="xml" version="1.0" encoding="UTF-8" omit-xml-declaration="no" standalone="yes"/>

Not sure if this is somehow supported. I remember that I had to solve it long time ago in the Flash version where it might have been hardcoded. If it does not work out of the box I think it does not work.