Does it help to replace the battery if phone is slow?
First of all, a phone would not just run slower like an old cassette tape deck. Either it has sufficient power to run, or it has dropouts - though mobiles switch off before dropouts occur.

My Android Phone can switch to some kind of "economy mode" either manually or automatically when battery charge falls below a given threshold.

This mode includes dimmer display, shorter display-on time and reduced background functionality (i.e. processes running in the background like position tracker, messenger, email, ...)

However, the phone notifies me about this, and I'm not aware of any phone that would switch to "eco mode" silently just because the battery is worn out. Also, many phones even don't know if their battery is worn.

A new battery will help if the time the old one lasts until charging is required has decreased a lot.

The main reason for a slow phone is that the old phone seems slow compared to new phones with faster hardware. Also, apps tend to need more and more resources from version to version, so a current version may run slower than an old one. Plus, all the stuff you installed over time may slow down the phone.