What "issues", exactly? What do you mean by "out of RAM"? MacOS is designed to use AS MUCH RAM as it can. Here's my 32Gb M2 Pro Mini, as it happens to be right now. It's using 23 Gb, and it has filled up the remaining 9 Gb with cached files.
If your memory
pressure is high, then that's a different story. Show us the summary from Activity Monitor, as I've done here.
But it may depend on what you do with your machine.