In the tutorial they do it a little different. A recordset value is used that is filtered on the id of the product or file. The tutorial has a link with the name of the item, this link has a URL parameter for the id of the file to download.
There is then a recordset on the page that is filtered by this id value. The end result is a recordset that has the correct file name in it. It is this file name from the recordset that is set in the download server behavior.
What we did was the easier way for how you had the page already setup. You could do it this other way if you wanted to, you would just need to have the id for the file post to the page instead of the file name, then you could have a filtered recordset based on the id of this item. If you had this filtered recordset in place on the page then you could reference the file name from it.