If the problem started occurring after installing the RAM, it is most probably caused by the RAM. Issues with RAM can be "spotty", meaning that it doesn't necessarily fail all the time - but just randomly or when the system is hot or similar. Therefore the RAM might be flawed even though the system passes the hardware test.
The error message in the screen shot shows a page fault within the kernel. This is typically caused by either a bug in the kernel, or a hardware error - usually faulty RAM or bus/CPU errors, but the latter is less likely.
As this happens during boot-up and a laptop is usually comprised of only expected hardware components - it is likely to be a hardware error.
If you have any external devices plugged into the laptop, for example Thunderbolt or USB devices - try unplugging to see if that solves the problem. Then the cause could be a buggy kernel extension.
You can try downgrading to an earlier version of macOS if you're certain it is not a hardware error. If it is a kernel bug, the bug might not exist in earlier versions of macOS.