Flexible modulation of sequence generation in the entorhinal-hippocampal system