Who was the commanding officer of the confederacy?

general Robert e. lee