Should I create a user for each website to protect the websites?

I have 5 websites on CyberPanel. I fear that if a website is infected with malicious code or attacked, it will spread to other websites.

So can I ask if creating a user for each website is a way to prevent the spread of malicious code? Or am I doing a redundancy?

Is there another way to prevent the spread of malware?

Thank you!

@lucidgen
If you concern this issue, you need to change OS to Cloudlinux (license), if using OS normally, create user by each user do not protect your code