You're on the right track with <xsl:number level="any"/>
, but you need to evaluate this instruction each time you want it. At present you're evaluating it once, storing the result in a variable, and then inserting that precomputed value every time.
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:template match="@* | node()">
<xsl:copy>
<xsl:apply-templates select="@* | node()"/>
</xsl:copy>
</xsl:template>
<xsl:template match="file_item_nbr">
<file_item_nbr>
<xsl:number level="any"/>
</file_item_nbr>
</xsl:template>
</xsl:stylesheet>