Although it’s in beta, Universal Control on macOS Monterey has been working well for me. One of the most delightful touches is how you interact with the setting to control how the Mac conceives of your iPad’s location. Perhaps unsurprisingly, Apple bakes this feature into the Displays setting in System Preferences.
Here’s my setup in Displays: Mac, attached display (extending the Mac’s display), and the iPad to the right:
Clicking on each device’s tile allows you to drag it into the space you’d like it to occupy relative to the main device:
Each device’s name is shown on hover. Nicely implemented, building on your previous knowledge.