Villa made it 2-0 just before the break before completing his hat-trick midway through the second half. By then Torres had been replaced by Cesc Fabregas as Luis Aragones made changes with the game won.
Russia pulled a consolation goal back before Fabregas made it 4-1 in injury time.
Xabi Alonso came on for the last quarter of an hour while Alvaro Arbeloa and Pepe Reina were unused subsitutes.
Sweden beat Greece 2-0 in the other game in Group D.
