Eat less calories then maintenance (what your body burns daily) and you will lose weight. Eat maintenance and you won’t gain or lose any. Eat over maintenance and you’ll gain.
Sure, you can to a keto diet and you’ll see some fast initial weight loss (water/glycogen storage loss), but do you want to eat no carbohydrates (bread, rice, etc?), feel like shit (because of no carbs) and have it all come back when you start to eat like a normal person again?