Turtling does not mean no army. If you get wiped mid game on King, it probably means you don't have enough troops to defend. With few, big cities, even a multiple front war shouldn't pose any trouble on King as long as you still have some troops to defend. This means more then just the Oligarchy free archer in your cities.
AI isn't that strong on King, but it's not as powerless as in Prince either. The issue is that on King, you can still beat the AI to every wonder, so the temptation to wonder spam is high. However, wonder spamming means you hardly have any defense.
Also, don't forget military techs. You can defend with out-teched units, but you can't defend with plain old archers against knights-trebuchets-crossbows attacks. Out-teched ranged also die very quickly if cought in the open ground, so they are better kept in your cities while you use stronger melee and cavalry to kill the ennemy ranged/siege units. Pikemen are great in the Middle Age as they come with a tech you need for Education anyway, so don't overlook them.
We can give better advices if you tell us when "mid game" is and why you are being beaten (does the AI have better units, or simply too much for you).
If several civs DoW you at once, almost certainly you look like an easy prey cause you have too few units.
And to answer your last question, no, you don't need to go offensive, but if you want a good peace treaty (where you gain gold/luxes rather than have to pay), you need to become threatening at least temporarily. This means move troops in his territory, start bombarding a city ... just killing his attackers won't help. If a warmonger is attacking you and he has captured other civs cities or city states, you can also go and free them. You won't be regarded as a warmonger for doing this, and this will help your relations with that civ/city state. Of course, we are back to point 1 : even when turtling, you need some army.
EDIT : beaten by several other member so it's possible i have repeated what they said