Gregg (L) Kathryn (R) and Lachlan Brain pose for photographers in Scotland's devolved Parliament in Edinburgh, Scotland, May 26, 2016. REUTERS/Russell Cheyne

By Elisabeth O'Leary

EDINBURGH (Reuters) - An Australian family who came to Scotland four years ago during a drive to attract people to live in rural areas, is now battling deportation under British immigration rules which changed after they arrived.

Kathryn and Gregg Brain and their seven-year-old son Lachlan, who has learnt Scotland's ancient Gaelic language at school, arrived in 2011 as part of a plan backed by the British government to help prop up an ageing and shrinking population in the Highlands.

"If we are not a poster family for successful immigration, I'm not sure who is," said Gregg Brain, a 48-year-old Australian health and safety expert who faces deportation on Tuesday along with his wife Kathryn, also 48, and Lachlan.

One of the key issues in the debate on Britain's membership of the European Union ahead of a June 23 referendum is the arrival of immigrants seeking work, and their status as beneficiaries of Britain's welfare system.

The Brains' potential deportation has highlighted the differences between Scotland, which needs immigrants to boost a shrinking population, and some other parts of Britain where immigration is perceived as negative.

"(Interior minister) Theresa May has said that she is happy to welcome immigrants who can linguistically and culturally assimilate, and pay their own way," said Gregg Brain. "We are also willing to live and work in a sparsely populated and economically depressed area of the country," added the health and safety expert.

A change in the rules since their arrival means the family now needs a different visa to stay in the country - a requirement that has pitted the devolved Scottish nationalist government against the British government in London.

"The government changed the rules before these people had a chance to benefit. The wee boy is a Gaelic speaker and is, to all intents and purposes, Scottish," said Scotland's First Minister Nicola Sturgeon following a meeting with the Brains.

Immigration is running well above government targets and data on Thursday showed net migration to Britain rose to 333,000 last year. The number of new arrivals from Europe has driven much opposition to the bloc.

"The (British) government apparently is trying to regulate immigration but what they are actually doing is alienating and deporting the very people with the talent and the skills that we need in Scotland," said Scottish National Party lawmaker Kate Forbes.

Kathryn Brain, who arrived on a student visa, has just completed a degree in Scottish history and has an offer of temporary work in a local distillery which she has been unable to accept until her regulatory status is clarified.

Home Office minister James Brokenshire said the family could submit a new visa application and he would meet their local member of parliament who had raised their case.

"He can be assured that the family does not face an imminent risk of immediate deportation," Brokenshire told lawmakers.

Brain said he bore no grudges.

"It was a dream for us to live in Scotland, and for that it is worth whatever it takes."

(Editing by Stephen Addison)