Because James Kirk was not yet at the time in his life when he would learn how to travel through time, it was left to Doctor Who -- the very FIRST Doctor Who, back when HE was young -- to transport the Ents back to the 21st century. There, the Ents had to avoid encountering their own selves who were holding their long meeting, but this was not difficult. So they spread out through the city, destroying the Zombies who were still dancing to "Thriller."