Are Kernel Codes (which are written in C) compiled during boot time?
Usually, everything is compiled in advance: the kernel and userland applications.

Roughly, the kernel is written in a special place on the disk (or other permanent memory), which the hardware will access at boot time, copy in RAM, and execute.

The kernel includes the disk driver and the filesystem driver, and will look for specific files on the disk, using them to load the first OS process (e.g. /bin/init, in unix-like OSs). This will in turn ask the OS to spawn new OS services/daemons, load new drivers, and finally start the user interface.

There is no need to have a compiler around during this. All the code which is loaded is machine code (already compiled).

The compiler is also not needed at installation time, since whoever produced the installation media (or network repository) wrote binary packages in it, containing compiled code.