You can never prevent a new version of Windows from installing. You can certainly delay receiving it, and I'll show you how I do that. But no matter what you do, you will eventually receive 24H2, because updates are cumulative. Microsoft's goal is for all Windows machines to be up-to-date, so you will receive missing components from 24H2 in whatever version of Windows follows 24H2.
My method is based on my opinion that almost nobody needs to get a new version of Windows on the first day it's available to the public. Only if your computer is experiencing a problem that is specifically addressed in a new version of Windows do you need to have that new version as soon as possible. Everyone else should wait.
We should wait because even though new versions of Windows are tested on literally millions of Windows Insiders, that's only a drop in the bucket compared to the more than one-and-a-half billion users of Windows.
I set my PC to delay receiving new versions of Windows for 90 days. That doesn't mean I'll get the new version on the 91st day - it means my computer isn't even eligible to receive a new version of Windows until the 91st day. It can take Microsoft 6 months or more to send a new version of Windows to its users.
90 days is usually long enough for Microsoft to discover problems in a new version of Windows and either fix them, or prevent parts of an update from going out to configurations that won't succeed with them.
This method has worked well for me. I have not had to uninstall an update since Windows 8.