Electron-ion recombination observed in storage ring experiments shows a significant enhancement of the radiative recombination (RR) rate for highly charged ions with low-energy electrons relative to what standard radiative recombination rates predict. To understand the fundamental mechanism of this enhancement we analyze the role of classical chaotic dynamics in the presence of Coulomb and magnetic fields in the electron cooler of the ring. Using a classical trajectory Monte Carlo method we investigate the dynamics of electrons in the toroidal merging and solenoidal interaction regions of the cooler. In the magnetic field inside the solenoid electrons are scattered by the ion multiple times involving irregular deflection functions with fractal-like structure. The net flux of electrons towards the immediate vicinity of the ion is changed compared to the pure Coulomb field, which influences the probability for recombination. However, at small relative velocities the magnetic field rather prevents the recombination of an electron with the target ion thus leading to a smaller recombination rate than the standard RR rate prediction. During the merging between electrons and ions in the toroidal-shaped magnetic field section prior to the solenoid a transient motional electric field in the rest frame of the ion opens an additional pathway for free-bound transitions of electrons. Accordingly, high Rydberg states get populated during the merging process. Radiative decay of these high-lying states inside the solenoid can stabilize a small fraction of the bound electrons. Thus, sufficiently deeply bound electrons contribute, in addition to the RR channel, to the observed electron-ion recombination rate. The obtained absolute excess recombination rates can account for the experimental enhancement. The scaling of the rate with the nuclear charge and the magnetic guiding field approximately agrees with the measurements.