But I think the RAM is the problem. Can someone confirm?
Indeed, that failed memtest confirms it. You have bad RAM in your system.
Now, the problem may be from the motherboard, from the memory bank, from the memory chips, ...
What you can do is to remove all but 1 or 2 of your RAM module and re-test. Are these good ? If not, try to move them in another memory bank. Does the test succeed in these ones ?
If you buy new RAM when it is your memory bus or bank that is bad, you will just have waste time and money.
Defective hardware like yours requires a complete an precise test of each and every component.