Matthew 5:38-45 (KJV)
38 Ye have heard that it hath been said, An eye for an eye, and a
tooth for a tooth: 39 But I say unto you, That ye resist not evil: but
whosoever shall smite thee on thy right cheek, turn to him the other
also. 40 And if any man will sue thee at the law, and take away thy
coat, let him have thy cloak also. 41 And whosoever shall compel thee
to go a mile, go with him twain. 42 Give to him that asketh thee, and
from him that would borrow of thee turn not thou away. 43 Ye have
heard that it hath been said, Thou shalt love thy neighbour, and hate
thine enemy. 44 But I say unto you, Love your enemies, bless them that
curse you, do good to them that hate you, and pray for them which
despitefully use you, and persecute you; 45 That ye may be the
children of your Father which is in heaven: for he maketh his sun to
rise on the evil and on the good, and sendeth rain on the just and on
the unjust.
In Matthew 5:38-45, Christ is providing information on the nature of the Kingdom of Heaven and the character of God. In these verses He shows that His kingdom in not a kingdom of retribution and forced equity based on physical laws. Instead, He shows that His kingdom is spiritual based on mercy and unconditional love. Under the law driven culture in Israel, seeking equity of your enemy through the law was extremely important. Jesus however, is telling us to love our enemies and do good to those who despitefully use us for this is the character of God. For God does not seek equity for our breaking the law but rather is merciful and forgives based on His love for the world through the sacrifice of Christ.
In verses 39-41, He gives three examples. In each of these instances, the “enemy” is forcing his will upon the other person, ie striking, suing and impressing into service. Per the law, the injured party has a right to recover what ever has been taken from him (Deuteronomy 19:21 – see below) to the point of recovering the “intention” of the enemy in the case of false witness. However, in these verses in Matthew, Christ says not to resist the evil and attempt to recover damages through the law but to go above and beyond the law to mercy for in doing so you identify yourself as a child of God who blesses all men equally.
With respect to your specific question on Matthew 5:41, Jesus is telling us not to resist if we are compelled to do something against our will. In that verse, the word “compel” is the Greek word angareuo, which means to impress into service. So, instead of resisting having to be required to walk a mile, show your willingness to comply by going an extra mile. So again, in all three cases, the “enemy” has done something evil with respect to the recipient. Jesus tells us not to resist the evil but only to meet evil with good for in doing so we reflect the character of our God and the nature of the Kingdom of Heaven.
Deuteronomy 19:16-20 (KJV)
16 If a false witness rise up against any man to testify against him
that which is wrong; 17 Then both the men, between whom the
controversy is, shall stand before the LORD, before the priests and
the judges, which shall be in those days; 18 And the judges shall make
diligent inquisition: and, behold, if the witness be a false witness,
and hath testified falsely against his brother; 19 Then shall ye do
unto him, as he had thought to have done unto his brother: so shalt
thou put the evil away from among you. 20 And those which remain shall
hear, and fear, and shall henceforth commit no more any such evil
among you. 21 And thine eye shall not pity; but life shall go for
life, eye for eye, tooth for tooth, hand for hand, foot for foot.