Harry Potter author JK Rowling has defended herself after being criticised for casting a Korean actor to play the character of Voldemort’s snake Nagini in the latest Fantastic Beasts film.

The revelation that Nagini would feature in Fantastic Beasts: Crimes of Grindelwald, emerged in a promotional video for the film released on Wednesday. The video shows South Korean actor Claudia Kim turn from a woman into a snake.

The Fantastic Beasts series has previously attracted criticism for its largely white cast, and while some are excited by Kim’s role in the film, others have raised concerns about a South Korean actor playing the role of Nagini. In the Harry Potter books, the snake is a submissive character that is the property of villain Voldemort, who drinks her “milk” for strength before he is restored fully to his body.

One critic wrote to Rowling on Twitter, saying “Listen Joanne, we get it, you didn’t include enough representation when you wrote the books. But suddenly making Nagini into a Korean woman is garbage.”

Rowling responded, writing that Nagini is a Naga, which are “snake-like mythical creatures of Indonesian mythology”, adding that “Indonesia comprises a few hundred ethnic groups, including Javanese, Chinese and Betawi”.

The Naga are snake-like mythical creatures of Indonesian mythology, hence the name ‘Nagini.’ They are sometimes depicted as winged, sometimes as half-human, half-snake. Indonesia comprises a few hundred ethnic groups, including Javanese, Chinese and Betawi. Have a lovely day 🐍 — J.K. Rowling (@jk_rowling) September 26, 2018

She also wrote that she had been holding onto the secret that Nagini was a “maledictus” – a human who had turned into an animal due to a blood curse – for 20 years.

But many thought Rowling’s response was insufficient. One Twitter user shared translated screenshots of posts from Korean viewers, angry about the casting. “An Asian woman who was on exhibit in a circus … Gets beheaded later and dies? She ate people as a snake in [Harry Potter]”, wrote one angry viewer.

Another objected to the way race was dealt with in the Harry Potter series. “You can’t be admitted to Hogwarts unless you’re English and we don’t know if there’s any wizarding schools in Asia, home of 4.4 billion people … [and] a homicidal white man traps an Asian woman inside a snake form and brainwashes her.”

Rowling has previously attracted praise for her support of the casting of Noma Dumezweni, a black actor, to play Hermione Granger in the London production of the play Harry Potter and the Cursed Child.

In 2015, when the casting announcement was made, Rowling tweeted: “brown eyes, frizzy hair and very clever. White skin was never specified. Rowling loves black Hermione”.

Rowling has confirmed there will be five movies in the Fantastic Beasts series. The first film, starring Eddie Redmayne, was released in 2016.

The second film, which is scheduled to be released this year has already caused controversy, for its casting of Johnny Depp as Gellert Grindelwald, despite accusations against him of domestic violence. It also stars Jude Law as a young Albus Dumbledore, and fans have expressed disappointment that the character – whom Rowling has confirmed is gay – will not be “explicitly gay” in the film.

The screenplay of Fantastic Beasts: Crimes of Grindelwald was written by Rowling, who is also a producer on the film.