In the past, you could check the Activation Lock on a dedicated official iCloud page by entering the IMEI number. However, Apple removed it a few years back. Now the only reliable option to check a device's Activation Lock is by having physical access to that iPhone or iPad.
But, there is a workaround that might work for some. So the tutorial below talks about that trick which involves using the Apple Support page to check the Activation Lock. If it works for you, great! If it doesn't, you can follow these tips to check Activation Lock before buying a used iPhone.