Simplest way to short two leads with GPIO
If you want to simulate a button press of an external system relays are good solutions as they are galvanically isolated. You can also consider using semiconductor relays. They aren't bulky and also consumes less current. There are also latching relays available which helps you save power too. 

If the button is on e the same system sharing common ground,as mentioned in the comment, you can simply connect one end of the switch to the ground or DC and then use the open collector pin to change the switch state.