Presidential elections are the first Tuesday after the first Monday in November by the Constitution. 1864 was the Presidential election year in that cycle.
The November elections are to pick members of the Electoral College who then elect the President and Vice-President. These votes are counted in January nowadays. Which matters little, since the Electoral College votes were counted in December of 1864 in that election.