Minecraft PC with controller?

Ol
1

Can someone please explain to me how one can play with the controller on the PC MC. Please explain easily.

Ol

Is an Xbox one controller (also connected to cable