You seem to be generating a file with tab-separated fields, and are claiming in your headers that this is the same format as a binary Excel spreadsheet uses. It isn't the format Excel uses. And the program loading the spreadsheet is letting you know that you are misleading people - possibly just yourself.
You should probably look into using an export format such as a CSV file; converting from tab-delimited to comma-separated is not going to be hard.