How do I rotate a part around a pivot point?

I’m trying to rotate a part around it’s pivot point, but have no idea on how to do it.
I don’t want to mess around with hinges, and want to make the rotation fully script-based.
robloxapp-20220307-1533483.wmv (1.3 MB)
image

Any ideas?