US Secretary of State John Kerry on Wednesday praised the millions of Iraqis who "courageously voted" in general elections, saying many had acted "heroically" in standing up to militant threats.