If you'd like to map a few keys to do things like save a file while in insert mode, you can use the imap command. This binds F2 to exit insert mode and save the file:
:imap :w
This binds F2 to exit insert mode, save the file, and re-enter insert mode: