Intolerance of 'incomers' is not a British thing, or a small town thing or specific to any country or region though - it's inevitable to some degree anywhere.
If somewhere has a quick change, people take time to adjust (not in any way suggesting 'all' people, but rather generalised 'people')
Back in the 50s & 60s the bigger British cities experienced large amounts of immigrants & there was the 'no Irish, blacks or dogs' thing.
Now, it's just the norm that there is a big melting pot - the adjustment was made & people were born into & grew up in the new normal, so it is their normal now & immigrants are just part of the furniture so to speak.
The smaller towns & more rural areas saw rapid change following Tony Blair allowing ungraduated migration in the 2000s, so the resistance & discomfort was inevitable as people saw, experienced or perceived huge change.
This too has started to settle & is now the norm for younger people growing up - but is still quite recent so it has not completely bedded in yet as a norm for all.
It's therefore not really surprising that the areas with higher numbers of immigration are more tolerant, as 'incomers' are entirely normal & usual; the areas that are displaying a backlash may have had lower numbers in comparison, but they were not 'used to' immigration in the way that the bigger, more cosmopolitan areas were.
There is intolerance to immigrants all over the world - including throughout the other EU countries, as well as Britain.
It's not a uniquely British phenomenon by any means.