A lot of F1 teams are UK based as its something this country is good at
I wonder what brexit might do to that
Probably nothing... There's barely one race a year here as it is
Ok...but don't the team return to base during, say, a two week layoff? Don't they have to ship parts from there?
Depends. Less than half the races are in the EU/Europe at the moment. They do tend to return to base between Euro races if there is a long enough gap, but for the fly-aways by the time they've packed everything away, loaded it onto airliners, flown it to the next place, and unloaded and unpacked it - it's time for the next race anyway.
AIUI teams typically start to arrive on the Wednesday before a race, and leave the following Monday. So with the profusion of back to back races this season they haven't really got back to base at all.
Flying out of parts is done on commercial airliners - often as hand baggage where possible. That tends to be reserved for urgent stuff where someone has stuffed it into the Arnco - twice.
The real 'brains' behind an F1 team (excluding top management obvs!) often don't actually attend the races. They're at the factory working on upgrades or next years car. The factory will be where they can get the best engineering staff.