Yes, an Apple device can be erased even though it is locked with an access code/passcode.
If the device is locked with an access code, Blancco Mobile Diagnostics and Erasure software automatically bypasses the access code by putting the device in recovery mode. This saves a lot of time since the user does not have to do this manually.
The manual process is described in Apple's documentation here: If you can't update or restore your iPhone, iPad, or iPod touch