If all you wanted was the new variable name to contain the filename, the new variable could be any format, not just STRING. Just change instances of the STRING command to the NUMERIC command.
For example:
begin program python3.
import os, spss
original="/Users/rick/DATA/languages/English/Employee data.sav"
fileinfo=os.path.split(original)
mypath=fileinfo[0]
myfile=fileinfo[1]
clean_filename=myfile.replace(' ','_')
spss.Submit("GET FILE '" + original + "'.")
spss.Submit("NUMERIC " + clean_filename + " (F8.2).")
spss.Submit("EXECUTE.")
end program.
------------------------------
Rick Marcantonio
Quality Assurance
IBM
------------------------------