The OpenCore Legacy Patcher is the industry standard for "jailbreaking" older Macs. It works by injecting a sophisticated bootloader that mimics newer hardware, tricking the modern macOS installer into thinking your 2012 machine is a supported model.
Modern macOS versions are optimized for efficient Apple Silicon chips. Your Intel Core i5 or i7 processor will run hot. Consider installing an app like Macs Fan Control to manually adjust fan speeds and keep the laptop cool. jailbreak macbook pro 2012