There is no red button with a x in it.
You could see one inside a web page where authors use windows symbols.

You do see a red dot button. It is the close button. Closing a window and closing an app are two different things in macOs. Decide what you want to do. Use the appropriate action.
To quit an application, I use command + q.
Windows lets you run the same app multiple times. macOS doesn't. if an app wants, it can open multiple windows. For example, start up word by double clicking on a word document. macOS starts up word. Word opens the document in a window. To edit a second document, you can:
-- double click on another document. Word will open the second document in another window.
-- command + n will open a blank document window.
The advantage of this is if you double click on the word app, you bring up the running word app.
R