So the book and the movie are loosely based on historical events?
No. The story is made up. The classes of submarines and a lot of the ships actually named were not.
There was an episode of a Soviet surface ship unsuccessfully trying to defect:
http://en.wikipedia.org/wiki/Soviet_frigate_Storozhevoy