I can't say exactly why. "dans" means "in" indeed, but it also has other uses.
We also use it for approximations : "Dans les cent euros." = "About a hundred euros."
It can also mean "during" : "Je le ferai dans la semaine." = "I'll do it during the week."
All these, including "frapper dans quelque chose", are expressions, it's not representing the usual meaning of the word "dans", but are still correct.
My (albeit brief) research says that "frappe" is most accurately translated as "hits" yet "kicks" is given as the correct translation. To me, hit/strike is a very different action than the very specific "kick". Sure, they're in the same region of meaning but wouldn't a more accurate translation for "she kicks" be "elle lance"? Or is this just lost along the lines of translation?
"to kick" means to hit with a foot
In French it's most of the time translated with "frapper". Sometimes we still need to specify the body part used, then we can use either "donner un coup de ...", or "mettre un coup de ..." (the three dots being the body part).
As for "lancer", it's translated "to throw" (when we're talking about people putting objects away from them, because "lancer" has several meanings).
"He kicks him in the knee." = "Il le frappe dans le genou."
"He throws the ball over the fence." = "Il lance la balle au dessus de la barrière."
We understand that going from the English "to kick" to French will be frapper. I think some of us are wondering how it is going from French frapper to English.... is it all just about context to determine whether we will say hit or kick? Oh, and thanks for all your explanations....always helpful!