@DetroitKp The type of device is internal to the core - if the core should expect a RetroPad (a logical gamepad) or other type of device - it's not for setting which physical device is connected - see https://docs.libretro.com/guides/input-and-controls/.
To designate the gamepad as P2, you just need to set input_player1_joypad_index, or input_player2_joypad_index, etc. For you, to set P1 as keyboard, you need to set P2 to have the index 0 (1st gamepad):
input_player2_joypad_index=0
which is what the configuration editor will do.