I tried prepending 011 to the number as you said but it didn’t work.
I’m using a “+1 409 123 4567” number (USA) to send the SMS to a “+506 1234 5678” number (CR). I’m using an USA number because the trial account in Twilio doesn’t let me choose one from Costa Rica. But I tested the communication in the Twilio API and it works.