By default settings, the screenshots are automatically saved to your desktop. When you want to save your screenshot in a specific file, you can adjust this. But keep in mind that this action requires macOS Mojave or later.