Enabling the arrow keys, insert key, and page up/page down keys in "vi" has to be done in a ".exrc" file in your home directory. See "man ex". The contents of the ".exrc" file depend on your terminal (or terminal emulator). For the root account I have more than one saved version and copy the one which matches the value of $TERM.
First check whether you have a ".exrc" file already to see whether you are going to edit it or create it.
The format of a .exrc file is very basic:
map key_you_press key_in_vi
map key_you_press key_in_vi
The "key_you_press" is the exact control sequence generated when you press that key. The "key_in_vi" is the key (e.g. "k") you would press in vi to get that effect.
I don't know how to generate a ".exrc" file using "vi". I use "echo" to generate mine.
For vt220 control sequences: