This article explains how to lock the mouse cursor to one screen in a multi-monitor setup using the Dual Monitor Tools software.
Super easy mouse cursor lock limiter! ► Quick solution for multi-monitor gaming and edge scrolling
Windows doesn't have built-in tools to lock your mouse to one monitor when you add a second monitor (although some full-screen games and applications do this by default). The Dual Monitor Tools application is the best way to control your mouse with two monitors.
Download Dual Monitor Tools and install it.
Right-click or tap and hold the Dual Monitor Tools icon and select Options.