You can perform searches and use text replacements from anywhere on iPhone without taking your hands away from Magic Keyboard.
Open Search: Press Command-Space.
Note: You can change the actions that are performed by the Command key (and other modifier keys like Caps Lock). Go to Settings Switch between keyboards with Magic Keyboard and iPhone