On Windows, file extensions are hidden by default . This has a number of consequences.
Two Files with the Same Name in the Same Folders
Two files in the same filesystem can't have the same filepath, which means that two files in the same folder also can't have the same filename. However, the filename includes the file extension. If we hide the file extension, it may look like there are two files with the same filename in a folder, even though there isn't.
For example, if we have a file called book.txt and book.jpg, both files will appear in the File Explorer with the name book by default, making it seem that they have the same filename.
Ambiguous File Types
In the past, files on Windows had icons and thumbnail-sized icons according to their file type, with exception of image files that had thumbnails generated from the image data they contained. With time, more and more file types gained the ability to generate thumbnails from their contents, such as documents, spreadsheets, PDF's, etc. Even music files may have a thumbnail generated from the cover of the music album.
Since the only information you're shown about a file is their filename and icon, it's no longer possible to tell the type of a file from this alone, as you can't see the file extension to tell its file type, and the icon can be anything the thumbnailing program can generate.
Viruses
Even before the spread of thumbnails, file type ambiguity was an key reason why Windows has so many viruses. On Windows, an executable file typically has an .exe file extension, and it can set its own custom icon. This means that in many cases a virus is simply an .exe that has a name like "Popular Song Title" and had its icon set to the Windows Media Player icon.
To an unsuspecting user, the executable virus would be identical to a normal music file, so they will double click on it expecting the Windows Media Player to open the music file, but that will actually execute the virus.