Body recomp

Is body recomp basically the process of losing fat while maintaining or even gaining muscle? Whenever i've read about it the articles make it seem like a dauntint task that is very hard. Would a keto diet be ok for this? I still need to lose about 20 more pounds but if the majority of my cals are coming from protein and I start working out is this feasible?
Angels