At least two people died and nine were injured in a head-on collision between two trains near Santiago.