It looks like the MDF file corrupted or not recognized. The simplest alternative is to use the existing backup to restore the database if you have a backup of this database.
If you cannot attach the previous database after upgrading SQL Server, try to attach the database using the sp_attach_db command.
See also the following posts.
After reading Olaf's answer, I tested that if a database has multiple data files with mdf extension, then if you use the mdf file that is not the primary data file to attach the database, the above error will indeed be reported.
Usually the recommended file extension for secondary data files is .ndf.