How to competently make an "FPS Controller"?

The problem is this: I want to make an “FPS Controller” out of a regular capsule, I wrote a control and all that, but the problem is that as the capsule moves, it falls =). I will be glad to everyone who will tell you how to make the capsule not fall when moving!

If you have a rigidbody attached to it, go to the component > constraints > freeze rotation