It's <Esc>, ':' 'q' <Return>. 'Esc' to return to normal mode. ':' to begin entering a command, 'q' to actually quit, and <Return> to send the command. For safety, vim does not allow you to quit without saving. You can either override this behaviour by appending a '!' after 'q', to tell vim to quit without saving, or use ':' 'w' <Return>, while in normal mode, to save the file first. Writing and quitting can be combined into ':' 'w' 'q' <Return> to save and quit.
I can't believe that there are still people that code in Vim, lol 😂. Not only that, but they encourage others to learn how to use it and code in it... WTF, I get that some people like retro stuff, but that's just plain stupid. Why not code in ASM then, it's retro as well 😂.