The scene is Britain, the time the not-too-distant future. The air hangs heavy with metaphor. Ever since a climatic event known as the “Change”, life has, well, changed. Movement between countries is outlawed. There isn’t a single beach left anywhere in the world. Britain’s coastline has been obliterated by a National Coastal Defence Structure, known to everyone who serves on it as the Wall. Every British youngster is conscripted to spend two years of their life as a “Defender”, patrolling 10,000km of concrete walkways looking for “Others” who might appear at any moment from the sea. Life on the Wall is cold. It is boring. It is utterly grim. It is a whisper away from the sort of vision you can imagine Sajid Javid using to unveil a Tory leadership bid.

This is the dystopia that John Lanchester has created in his fifth novel, an environmental fable that manages to be both disquieting and quite good fun at the same time. It’s a calculated extrapolation of our present anxieties about rising sea levels, anti-refugee populism, post-Brexit scarcity and intergenerational conflict, so day after tomorrow that it’s all but guaranteed to be invoked in newspaper columns and kitchen-table debates.

One of the things Lanchester is brilliant at, both in novels such as Capital (2012) and especially in his journalism and nonfiction, is simply explaining stuff. He is adept at breaking down complex concepts into accessible language peppered with handy little reminders – like a leather-jacketed professor taking a seminar in the pub. He bestows some of this eloquence on his affable, bespectacled narrator, Kavanagh, a rookie Defender from the Midlands who manages to find countless amusing ways to describe his dark, unforgiving stretch of the Wall in north Devon. “Always water, sky, wind, cold, and of course concrete, so it’s sometimes concrete-waterskywindcold, when they all hit you as one thing, as a single entity, combined, like a punch, concretewaterskywindcold.”

Lanchester has always made Britain, or the British abroad, his subject. Now he recasts our country as a frigid fortress, where national service and a diet of “turnips, turnips, fucking turnips” are endured with a needs-must stoicism. The narrator’s tone may be chatty, but the world he inhabits is savage. The incomers who make it over the Wall are put back to sea or put to death. If they can prove they have valuable expertise, they can serve as “Help”, a euphemism for state-coordinated slavery whereby any citizen can “borrow” useful refugees. In rare cases, a highly skilled Other might even work their way up to be a Defender, as in the case of Kavanagh’s captain. He, somewhat implausibly, pulls himself up the food chain only to prove that the system is not as infallible as it appears.

It’s hardly a cakewalk for young Defenders such as Kavanagh, whose conscription begins at a point of national crisis. Others are marauding in “big numbers, dangerous numbers” (more than 94) according to a politician (known as “the blond baby”) who visits the troops to deliver platitudinous pep talks. It comes as no surprise that the young are disgusted by “the olds”. They are responsible for the Change but have never done time on the Wall, which is, as Kavanagh says, “the single most important and informative experience in the lives of my generation”. When he visits his parents, they can’t look him in the eye, ashamed that the world “broke on their watch”.

Kavanagh secretly aspires to join the supposedly meritocratic “Elite” who are occasionally spotted flying overhead. In the meantime, his only escape route is becoming a “Breeder”, exempted from national service to produce children. It’s an idea he’s prepared to indulge if it means he gets to sleep with fellow Defender Hifa, but this half-hearted romance plot is soon disrupted by an attack that blurs the line between insiders and Others.

It’s a clever, clairvoyant concept. Lanchester reveals with slow, steady control the cruelties of his strange new world and then socks you with their philosophical implications. We can’t help but breed, optimistically and selfishly. We ultimately must trust our seniors, even when we know they are lying. If you’ve listened to any radio phone-ins about the discovery of refugee boats in the Channel, you’ll know that the fear of Others is barely overplayed either.

So why, then, is The Wall a little unsatisfying? One problem is that it’s not nearly strange enough – the ambient unease rarely trickles down to a human level. There is one sublimely odd moment, when Kavanagh’s parents wait until his departure to watch a surfing documentary, but it stands alone. What would the Change have done to a country’s psyche, its folklore, its language? Who are its celebrities? How does the culture of the past relate to the culture of the present? None of these questions feel fully imagined.

Despite being very different to Lanchester’s last novel, Capital, The Wall suffers from some of the same flaws: underdeveloped characters, particularly the women, a lack of convincing detail and an overly schematic plot. We’re rather blessed at this moment with prophets of dystopia: George Saunders, Margaret Atwood, Charlie Brooker, Naomi Alderman, Nana Kwame Adjei-Brenyah. The Wall feels a bit basic by comparison. But it’s resolutely British at least – and you can’t help wondering if it’s the dystopia our lonely, windswept islands deserve.

The Wall by John Lanchester is published by Faber (£14.99). To order a copy for £9.99 go to guardianbookshop.com or call 0330 333 6846. Free UK p&p over £10, online orders only. Phone orders min p&p of £1.99