These changes are phonetically "natural" in some sense. For example, [y] (this would be [j] in IPA) is very close to [i] in articulatory terms: both are pronounced by putting the tongue tip close to the alveopalatal region (and both are voiced, with no lip rounding). The only real difference is syllabicity. Depending on where in a syllable such a sound is, one would be likely to develop into the other; indeed, there may be variation between the two depending on how fast one is speaking. There are words in some languages where it isn't clear which is the "correct" phonetic or phonemic transcription, like Spanish 'tiene' ("he/she has").
As for the [k] developing into [ky] > [tʃ] > [ʃ] > [s] before front vowels (as happened going from classical Latin to Spanish and other Romance languages), the [k] is pronounced by raising the back of the tongue into contact with the back of the mouth, while front vowels are pronounced by raising the front of the tongue more towards the front of the mouth (specifically the alveopalatal region). In many languages, the place where the [k] is formed moves--over generations--towards the place where [i] is formed, perhaps as a way to ease the articulatory movement. Indeed, if you're a native speaker of English (and many other languages), the place where your tongue contacts the roof of your mouth is further forward for the word 'keep' than for the word 'coop'. (Same for the [g] in 'geek' vs. 'goop'.)
It's also the case that some sounds formed in different ways in the mouth sound similar. For example, it's possible to form a fricative sound by touching the lower lip to the upper teeth, as in English 'fill'; but it's also possible to form a similar sound by moving the lower lip close to (but not touching) the upper lip. Many dialects of Spanish have the latter sound in words like 'foto'; I believe (but I'm not sure) that some dialects have instead the English-like 'f' sound in such words. Sound changes like this can happen (probably) because of mis-perception of the similar sounds.
Language contact is probably another source of sound change, e.g. Romanian may "sound like" Slavic languages because it's been in close contact with them for centuries or even millenia, and/or because at some point Slavic speakers had to learn Latin as a second language, and brought along their pronunciations, as modern language learners often do (think of French or Russian accented English, or English accented French or Russian). This tendency is especially pronounced (sorry for the pun) in people who learn the second language in their teens or later.
There are many linguistic studies on these and other sorts of causes of sound changes. You could start with the Wikipedia article on 'sound change', and the references provided there. Another good (but not free) reference is Juliette Blevins' book "Evolutionary Phonology" from Cambridge Press. Juliette has a short article on the topic here: https://julietteblevins.ws.gc.cuny.edu/files/2013/04/ColumbiaPhon2015cms.pdf.