At the heart of I Am Not a Witch, a Zambian-set highlight of this year’s Cannes Festival, is an eminently relatable dilemma: should you remain living as witch in a travelling camp for tourists? Or liberate yourself, and thus risk being magically transformed into a goat as punishment? Who hasn’t wrestled with that one at some point or another? “That’s a choice I feel like I, as a woman, make all the time,” says Rungano Nyoni, the film’s Zambian-born, Cardiff-raised director. She laughs. “Shall I become a goat? Or shall I become a woman and live with all the injustices and difficulties that come with it?”

In Nyoni’s conversation, as in the society she depicts on film, metaphor and literal truth can sometimes become entwined. It is one of the qualities that makes her debut feature, a satire about a nine-year-old girl who is accused of witchcraft, so beguiling. The selection of I Am Not a Witch for the festival’s directors fortnight is a particular achievement for a first-time feature director, since this section is a breeding ground for future auteurs. It is the afternoon before she is due to fly out to France, though, and Nyoni says she is still struggling to relax into her success: “I’m more nervous than anything … it’s waiting to see it in front of an audience. That either reassures you or makes you even more nervous, so I think that’s when I’ll know.”

The initial inspiration for Nyoni’s screenplay took place a long way from both the Côte d’Azur and the relaxed, Cardiff coffee shop we meet in. It was one summer when she was staying with family in Zambia, as she explains: “My neighbour came over, screaming, saying her grandmother was a witch and had turned into a snake. My grandmother did a major eye roll. She was like, ‘Oh God, she just wants to get home and she can’t afford the bus fare. It’s stupid.’ But the neighbour really seemed to believe it.”

Does Nyoni believe it? Both the director and her film remain agnostic on the subject of witchcraft which, she says, is beside the point anyway. “It’s not the belief that I’m against, or that I question, because spooky things happen all the time in Zambia. It’s that the witch accusations, are always aimed at older women or children. This is the bit I find absurd.”

Nyoni further researched her script by visiting one of Ghana’s real-life “witch camps”, quasi-governmental settlements that are part-sanctuary, part-prison and part-tourist attraction. She lived alongside the women there and a version of the camp became a setting for the film, but Nyoni substituted the real details of camp life for more cinematic ones of her own invention. In the film, for instance, a giant bobbin of white ribbon is attached to the waist of the accused witches, including nine-year-old Shula, and wound in or out to control their movements. Equally visually striking are the film’s landscapes, great swathes of ash-grey, fire-fallow farmland, chosen, says Nyoni, “to reflect this idea of exploitation.”

Wales and Zambia are very, very similar in terms of being super laid-back and what you see is what you get Rungano Nyoni

Maggie Mulubwa, the young star of I Am Not a Witch.

Most impressive, though, are the touching, often very funny performances Nyoni has elicited from her non-professional cast. “My tribe is Bemba, but I didn’t want it to just be a Bemba monopoly, so when I did the casting I wanted to get different people from all different parts.” Her actors were then encouraged to improvise dialogue in English, Bemba, Nyanja and Tonga, only two of which Nyoni speaks fluently. “It makes it more tricky, I realise that now.”

Looking for the right child to play Shula, was even more challenging, and involved auditioning nearly 1,000 children. “I think, if you cast right, kids are the best to work with because they don’t think about it too much. That’s why the thousand kids.” Eventually Nyoni’s location manager, who also happens to be her husband, reminded her of a photograph he’d taken of an interesting-looking girl in the north of the country. “From the picture, we contacted the chief, WhatsApped him a picture; he sent a WhatsApp to all his people and they covered, like, thousands of square kilometres to find her.” Once found, Maggie Mulubwa agreed to be in the film and, accompanied by an aunt, travelled 12 hours by car to join the shoot.

Maggie has since been justly awarded for both her courage and her nascent star quality; Nyoni set up a GoFundMe page to pay for her education and Film4 and the BFI have both pledged support. She will also join I Am Not a Witch’s cast and crew for the film’s Cannes premiere. “We only found out today and I’m so chuffed.”

When Nyoni was Maggie’s age, her family had just moved from Lusaka to the Riverside area of Cardiff. Due to visa issues, she didn’t return to her country of birth until she was 15, and so is as much Welsh as she is Zambian. She says her perspective as a film-maker has inevitably been informed by her semi-foreigner status: “You’re always watching things from outside, you’re not quite in.” Although, actually, she says, these two countries, over 7,000 miles apart, have more in common than you might think. “Very, very similar in terms of being super laidback and what you see is what you get. There is no pretence, there’s no trying to figure out what someone is telling you … Thank God my mum didn’t get to London!”

Nyoni did make it to London herself, however, studying for an MA in screen acting at Central St Martins, only to decide halfway through that she would rather be behind the camera. “I just lost interest in it and I was too self-conscious. But I’m glad I finished the course; studying acting was the best film school.” After graduating, she made a series of well-received shorts, including 2011’s Bafta-nominated Mwansa the Great, also set in Zambia and, in 2014, the multi-award-winning Listen set in a Copenhagen police station, Nyoni insists her next feature will be set in Wales.

Earnest films work against the subject. People watch, they feel bad for Africa, then they feel good that they feel bad Rungano Nyoni

Witch report … Nyoni’s impressionistic depiction of a witch camp. Photograph: film company handout

In the meantime, it is hard to place her work within a Zambian film tradition, if such a thing exists. “The Zambian film industry is very young … I think they tend to follow the Nigerian model, which sort of tries to follow the Hollywood model.” Nyoni cites a 1992 film from Senegal, Hyenas, as an influence, but it’s Michael Haneke’s 2001 film The Piano Teacher, about a self-harming woman living in Vienna which she describes as “my film school”. “Somehow, I felt like she was me and I felt like, if he can do this, this Austrian guy, make me want to relate to this bourgeoise white woman who plays a piano … That’s always what I want to do; find how can I make people engage with this story more, rather than distancing themselves from it. That’s the thing.”

At Cannes in particular, part of the appeal of I Am Not a Witch may be the window it appears to offer into an unfamiliar culture. But Nyoni is wary of pandering to the audience’s desire for exoticism. “I thought about making it realistic and drama-orientated, but I always think when I watch these earnest films that they work against the subject, in a way. People watch it, they feel really bad for Africa and then they kind of feel good that they feel bad.”

For this reason, it was important that Shula not be the typical cutesy, wide-eyed victim. “Usually kids are used to show some sort of innocence and I was trying to avoid that,” she says. She adopts a simpering child-like voice: “Like, ‘Oh, look at me! I’m a witch, what’s gonna happen now?’”

In fact, the nine-year-old protagonist of Nyoni’s film was named with a more kick-ass role model in mind. “My mother used to tell me all about my great grandmother Shula, who did an amazing thing for her time. A chief wanted to make her his seventh wife. She said, ‘I’ll marry you, only if you remain monogamous’; and that’s unheard of, you can’t do that. She was the oldest and the ugliest of them all, but that’s what she wanted and she got it.” This Shula has since become the standard to aspire to in the Nyoni family. “Shula is always like the spirit who follows everyone, just to say, get your stuff together.”

One suspects this revered ancestor would have had no problem with the film’s central dilemma. “She’d be a goat.”

I Am Not a Witch screens on 25 & 26 May at the Cannes film festival