I'm speaking from my personal experience , I used to train while being in caloric deficit for like 9 months during that period though I got stronger , I did not build muscle significantly in-spite of consuming 1g of protein/lb.
Now I have lost enough weight , I am in a maintenance level so I have started to gain muscle.
So , though hypertrophy does not happen as effectively as when you are in a caloric surplus or in maintenance calorie.
Your fat is basically cache reserve of energy which is saved for hardship , now when you're in a deficit your body starts to burn this but it might also accidentally burn some muscle too , So your workout protects this from happening but it is not 100% efficient.
In order to build muscle, your muscles need three things: exertion, rest, and fuel. 
The exertion and rest portions come from a proper workout and rest routine. The point of concern for your question is the fuel aspect.
A calorie surplus is recommended for muscle growth (hypertrophy) as most individuals don't eat enough to build the muscle mass they're looking for. However, the additional energy input doesn't need to come from a calorie surplus. If your body has energy stored in fat it can use that energy to build muscle mass as well, meaning, you can also build muscle in a caloric deficit if the circumstances are appropriate. 
This doesn't mean fat magically turns into muscle. It just means the energy is available.
The process works best in a slight caloric deficit (500 to 750) with high protein intake. Research has shown that 1.4 - 2 g of protein/kg body weight (0.6-0.9 g/lb) is ideal for muscle growth.  Further research has shown that 2.3 to 3.1 g of protein/kg of lean mass (1-1.4 g/lb lean mass) in a hypocaloric diet is required to maximize lean muscle retention. 
Will muscle just build a lot slower while I'm trying to lean down?
The short answer is yes.
While it is not impossible, building muscle and losing weight at the same time should be a slow and steady process. You're attempting to push your body into an energy-intensive change (build muscle) while restricting the energy available (calorie deficit).
Anecdote: In the first half of this year I was working out with a protein intake of 1 g/lb but trying to lose some excess fat by doing a calorie deficit. I definitely saw strength increase, lost 10 pounds, but I can't say I noticed much in terms of muscle growth. In the second half (roughly July to now) I reevaluated my goals and priorities. I kept my protein intake the same but upped my calorie intake to a surplus. My strength has increased more, I am noticing muscular improvements, however, some stomach fat has returned. This time around though it doesn't bother me as much, I know I can lose it.
speaking of building muscle has a lot of combined fact together nutrition rest and exercise and in your case the problem with caloric deficit is a lot of people miss understood it because they just goes lower on there calories intake but the truth is you star slowly to let your body adapt to your new diet and by lowering your calories you should rise you protein intake in the other hand to let your body to repair and build it self and also the protein your take will be divided to two portion the first one goes to build and repair and the extra amount your body will transform it to a source of energy and that what you need while your in your caloric deficit to gain extra muscle and to not let your your body break fro it own to use as a energy source