Also try using the Include button from within HA and not the Z-Wave JS Control Panel, it seems to work better for some reason. In the newest Z-Wave JS version (5.5.3) there will be an option to force S0 security inclusion, that might improve some stuff.
Depending on the lock manufacturer and type you will probably find some recent topics regarding some similar issues.