On the Mac, nearly every file has an extension. This extension is a set of characters after the name of the file. There will be a period between the file name and the extension. This extension indicates what type of file it is and it also determines which app opens it. For example, .png indicates a PNG graphic that opens in Preview by default, .pages denotes a Pages document, and .docx identifies a file as belonging to and opening in Microsoft Word. Applications even have an extension, the extension being .app. Most of these extensions are hidden by default on the Mac.
Depending on what you do, how often you exchange files with people on other platforms, and your personal preference, you may wish to see more or fewer extensions. You control that in Finder > Preferences > Advanced, with the “Show all filename extensions” checkbox. Individual files can override the setting, so if an extension isn’t doing what you want, select the file, choose File > Get Info, and check or uncheck the Hide Extension checkbox in the Info window.