You are right that at the very initial moment, where the wire pieces are attached to the battery terminals, they are at a different potential than the terminals themselves.
But that equalizes itself in a blink of an eye.
The negative battery terminal is stuffed with negative charges. They all repel each other. We call this high potential.
When you attach a wire piece to this terminal then suddenly these charges have another place to go where the repulsion is smaller (where the potential is lower). So they move there. The potential falls on the wire.
As they leave the terminal, the battery carries new negative charge to the terminal continously so it always is at the same potential. This new negative charge will then also move away.
This continues until just as much charge is located at the wire piece as is at the terminal. Only then will the charges stop moving. If there was a difference, then the repulsions would be different (the potentials would be difference), and the charge wound still be moving. Only when the charge accumulations are the same (when the potentials are equal) will the chare stop flowing.
The same goes for the positive terminal, just with a lack of charge and thus attraction rather than repulsion. Since the battery always keeps its terminals at a specific potential, the above explanation tells why the attached wire pieces will get that same potential.