Apple's iOS activation lock is a feature found in Apple devices that prevents theft. However, if the device needs to be handed over to a new user, you would have to first disable the "Find My iPhone/iPad/iPod" settings. For best practice, it is better to entirely remove the Apple ID logged into the device.
If you have the access to the device
Settings > Apple ID > Sign Out
If your screen differs from the screenshots above, it is possible that you are on a previous version of iOS. If that is the case,
Settings > iCloud > Sign Out
If you don't have access to the device
Visit www.icloud.com and log in with your Apple ID. Click on the Find iPhone icon.
Navigate to the top of the screen and click on the iPod/iPad which you have returned and Erase iPod / Erase iPad
It will prompt you to enter your Apple ID. It may also prompt to ask you to answer your security questions.
Click on Erase iPod / Erase iPad. It will prompt you to enter your Apple ID password. Only after you have removed the device it will be removed from your account.