Human Flow, the debut feature from the Chinese artist Ai Weiwei, is a bold documentary about the refugee crisis. The film bounds from the cardboard cities of Europe to the burning oilfields of Mosul and from the unmarked graves of Turkey to the Texas-Mexico border. It plays out across 23 different countries. It contains a cast of thousands. In 2010, the artist packed Tate Modern’s Turbine Hall with 100m hand-painted porcelain sunflower seeds that broke up underfoot and filled the air with dust. Here, he crams an entire global tragedy into 140 fraught minutes.

If there’s a unifying thread in all this teeming human traffic, it’s the shambling figure of Ai himself. There he is, a burly, beetle-browed man of 60, handing out hot tea on the beaches at Lesbos, comforting a traumatised woman inside a makeshift studio and cooking kebabs on a barbecue at a dusty refugee camp. He says that he never wanted to appear on-screen as a tourist. His mission was always to find common ground. “I am a refugee, every bit,” he says. “Those people are me. That’s my identity.”

Human Flow premiered in competition at this year’s Venice film festival. Ai says he’s astonished; he never imagined this happening. So now he sits in the foyer of a five-star hotel, gulping from a glass of iced-water and periodically getting up to shake hands with well-wishers. His sky-blue T-shirt is matted with sweat and his bristling beard looks as though it has spent the night in hard frost. But if you’re going to identify as a refugee, there are worse places to shelter. Ai has seen them and been there, and survived to tell the tale.

Even those who would struggle to name one of Ai’s installations are familiar with the man’s history. He’s the dissident artist, at odds with his homeland; jailed for 81 days back in 2011 and now, for all practical purposes, living in exile in Berlin. ArtReview magazine once called him “the most powerful artist in the world”, a visionary who has taken a lifetime of social activism and conjured it into a kind of continuous performance piece. His critics view him rather differently: as a crude provocateur, trading in stereotypes and bankrolled by the west. His presence in Venice is hardly going to assuage their concerns.

Ai shakes his head; he knows this line of attack. “All day long, the media ask me if I have shown the film to the refugees: ‘When are the refugees going to see the film?’ But that’s the wrong question. The purpose is to show it to people of influence; people who are in a position to help and who have a responsibility to help. The refugees who need help – they don’t need to see the film. They need dry shoes. They need soup.”

The artist in a refugee camp in Macedonia last year. Photograph: Valdrin Xhemaj/EPA

It helps, of course, that the film is such an extraordinary feat – a sweeping humanitarian epic with its feet on the ground and dirt under its nails. In one memorable shot, taken by a drone over a camp in Iraq, the beige tents are arranged like some vast abstract canvas. Then it drops by degrees to show us all the people who live there. Ai puts faces to statistics, tells individual stories and shrewdly decides not to spare his own blushes. At one stage, he playfully swaps passports with Mahmoud, a refugee fleeing Syria. Mahmoud, for his part, is happy to do so. He adds they should probably swap houses as well: a nice Berlin studio in return for a hot, crowded tent. The director chuckles gamely, but won’t take him up on the offer. It’s a moment that exposes the gulf between them.

Ai winces at the memory. “Yeah, that was the worst feeling. That really got me. Because [if] you’re passionate, you think you mean what you say. You tell these people that you’re the same as them. But you are lying because you are not the same. Your situation is different; you must leave them. And that’s going to haunt me for the rest of my life.”

He was raised in the teeth of the Cultural Revolution, the son of a poet who fell foul of the party. The family home, then, was in exile, first in Manchuria and then a labour camp on the edge of the Gobi desert. His father was put to work cleaning toilets; he attempted suicide several times. Witnessing that helped shape Ai’s worldview. “My father went through an unthinkable journey,” he says. “But it was one small section of a wider human struggle. There’s no end to that struggle. It’s the reality we deal with. We all have a short life. We have only a moment to speak out or to present what little skills we have. And if everybody does that, maybe the temperature changes.”

The Human Flow trailer.

Back in Beijing in his late teens, Ai enrolled at the film academy. Cinema, alongside poetry, was probably his first love. He adored the work of Fellini, Taxi Driver and the Godfather movies, yet now feels the heyday of narrative film has passed. “If you watch the news, you realise that film has lost its advantage in showing daily reality,” he says. “So it’s over, it has gone, it has already happened. We have too many images on the internet every second. Spend half an hour on social media and you get much more information than you could ever get into a film.”

He took his first flight from China in 1981, when he boarded a plane for New York, intending to shake off his shackles and start a new life in the west. He still remembers his descent into JFK. “It was like a sci-fi movie; like being dropped on to an alien planet. All the language, the knowledge – they just didn’t work any more. I looked out of the window and saw the city below. The flood of light – that totally absorbed me. Because I grew up without light – not even candles – just this very low-quality gas; the fumes would make your mouth black. And then, all of a sudden, to see those lights. All that energy; that surreal monster city. I felt like a moth. I wanted to die in those lights.”

At the time he referred to himself as an artist. These days he says that wasn’t really the case. He worked on building sites and as a gardener; very occasionally as a sidewalk caricaturist. Pretty much everything that he painted he tossed in the bin. New York was an education, but it never became home. It was only back in China, in the early 90s, that he finally began to find his range.

Ai’s work is rooted in conceptual art and dadaism; mercurial Marcel Duchamp remains a vital touchstone. So he found objects and then set about them, often with subversive intent. He smashed an antique Chinese pot for his photo triptych Dropping a Han Dynasty Urn; doused others in industrial paint for the exhibit Coloured Vases. And as he gained in confidence, his activism crept into the art to the point where the two elements became indistinguishable from each other. “All creative activism, if it works well, is a work of art,” he tells me. “The same way that every good work of art, if it concerns itself with reality and politics, is a form of activism. Sometimes, yes, they are separate. But maybe not for me. I was born into all that. I am used to it now.”

His run-ins with the authorities are not just a biographical footnote. One might better claim that they are central to his art. First, he outraged the government with a political blog. Then he hounded them over their listless response to the 2008 Sichuan earthquake, documenting the names of every student who perished and mounting a huge installation of 9,000 children’s backpacks. For his trouble, he has been thrown into jail and punched by police. When the blow was revealed to have caused a bleed on his brain, he filmed his medical treatment and posted the picture on Twitter. In this way, perhaps, even the plastic bag of his blood becomes an Ai Weiwei work of art.

A scene from Human Flow.

He describes his present base in Berlin as a dormitory existence. He says that he doesn’t speak German and rarely leaves his studio. He works through the weekend and says he never takes vacations. And all this is OK; the work keeps him occupied. “Also, it’s still very dangerous for me to go back to China. Twelve of my lawyers are still serving sentences. One for five years, another for 10. I call my mum on the phone; she’s well over 80. And she always tells me, ‘Don’t ever come back.’”

I ask what he thinks of China’s current prospects. To a western eye, his homeland looks to be in the ascendancy. It is well placed to profit from the actions of a wayward, bellicose US administration; poised to become the undisputed global superpower.

But Ai pulls a disgusted face. He thinks I’m missing the point. “Can China be a global power? I don’t think so. It can gain an advantage, that’s true. But it doesn’t have soul. It doesn’t have heart. It doesn’t trust its own people. So it has no self-identity in the sense that it has never accepted human rights as common values. No freedom of speech, no independent judicial system. If those don’t exist, how can you have creativity? How can you be a country? So forget about China. China is an illusion. It’s there, it’s large. But nobody can tell you what it is.”

The way Ai tells it, he exists in a perpetual state of flux; rootless to the core. He likens himself to a leaf on a stream, carried this way and that, never knowing where he is going to wind up next. Up to a point, this makes perfect sense. But it strikes me that there’s another way of framing the man’s story; one in which he is a far more active agent. In this version, Ai has spent his life in opposition to his homeland – in a perpetual state of friction, not flux. If anything has defined him, it is his relationship with China. Without China, I suggest, he wouldn’t be an artist at all.

“Yeah, exactly,” says Ai. The notion pricks his interest. “I would be what?” he asks. “Without all the yelling, without the prison, the beatings, just what would I be? Probably right now I’d be walking down Broadway, just like all the other immigrants. Trying to find the next job, pay next month’s rent. Or I’d be back in China, running a restaurant. Or in a suit, in an office, another Chinese citizen.” He reaches for his water. “But maybe not, even then, because my father was a poet. He brought me up on Whitman, Neruda and Rimbaud. All that made me feel there was another possibility, and that struggle means freedom. That, I think, is the revenge of life.”

Does he ever wish that it could have been different? Imagine for a moment there had been no banishment to the desert. No humiliated father, no prison, no Berlin. He might have led what passes for an ordinary existence. Wouldn’t he sometimes prefer to be running a restaurant in Beijing?

“Good question,” he says. “Of course you are human – you sometimes wonder these things. But I still think I would choose exactly the same path, even though the steps that I have taken have been very hard. It has been so ugly, so painful, but it has also brought so much joy. I think I’m a person who finds joy through difficulty.” He barks a short laugh. “No difficulty, no joy.”

•Human Flow is released in the US on 13 October and in the UK in December.