Any open file should also have a sister lock file in the same folder. Lock files should be deleted automatically when the regular file is closed. If that failed (typically due to a crash) you won't be able to open the real file until you manually delete the old lock file. Close inDesign and wait a few minutes, then check for lock files and delete any you find.
To export .idml open the file (outside the book panel), then File > Export... and choose IDML from the list.