The built-in features of Windows never seemed to work for me so I use an application called Spacedesk.
On the laptop you want to use as you main screen computer, install Space Desk Server
On the laptop you want to use as the second screen install and run spacedesk client. Your main laptop should name or ip address should show in the client software. Click the computer name/ip address and then you can use the second laptop as a screen for the main one.
Unless you have some extremely exotic laptop this cannot be achieved in hardware, unless you use an additional usb HDMI capture device, but I don't know how well that would work.