Depends on what the law is where you are. Many countries they are required to unlock devices that are fully paid for.
Now there might be technical restriction if for example the device does not function on the correct radio bands. That though is different than unlocking it. For example you could unlock a GSM phone and it still will not function on a CDMA network.