If you have questions about the conjugation of острог or Russian nouns in general, you can practice and get feedback from a professional tutor.
Только силой Господа удалось уйти из острога.
I say it was Divine Providence what escaped us from jail.