To install and use keras on your pc, you need to install the package and after that a special install function. It is best to do this in a clean R session, so outside of a script you are currently working in. After installing the keras package, install the underlying software keras depends on using:

keras::install_keras()

After keras::install_keras() has finished successfully R will likely reboot. From now on you can use keras by solely running library(keras). R will probably also output some warnings related to a failed GPU installation when you use certain keras functions. Don’t worry about this, because you’ll only train and predict relatively small neural networks that are able to run on a CPU.