The ultimate goal of any successful competitive swimmer is to be as technically sound as they can possibly be whilst also getting as fit as they can possibly get. It's the combination of those two things that add up to make the 'perfect' race. By technically sound, I'm talking about both stroke technique and set pieces such as starts, turns and finishes.
'Drills' are exercises that are used to help improve part of a stroke. By improving parts of a stroke, the overall stroke also improves.
The common pattern is for swimmers to engage in a pattern of 'swim, drill, swim' or 'whole, part, whole' as I was taught many moons ago.
Swimmers, swim a stroke and either they or a coach identify a weakness. They then engage in some drill work to try and improve the weakness before swimming again aiming to keep the improvement in the stroke as they do.