I have just noticed that evil is a part of devil. Is it coincidence?
Looking at http://www.dictionary.com/browse/devil?s=t
Origin of devil before 900; Middle English devel, Old English dēofol < Late Latin diabolus < Greek diábolos Satan
English Language Learners Stack Exchange is a question and answer site for speakers of other languages learning English. It only takes a minute to sign up.Sign up to join this community
English is a quirky language because it's primarily a mix of two separate linguistic families -- those languages that come from the Latin, particularly Old French, and those languages that come from the Germanic, particularly Anglo-Saxon. Sometimes two words from each of these branches look and sound very similar, but stem from completely different roots.
Such is the case with evil and devil. As you say, devil comes from the Old English deofol, from the Latin diabolus, which in turn derives from the Greek diabolos. Because of its use in the Church, it's a word that has permeated many European languages, in much the same form, Portuguese: diabo, German: Teufel, Danish: djævel, Dutch: duivel, and so on.
Evil however is from the Old English yfel derived from the Proto-Germanic ubilaz. This is why the languages that derive from the same source have similar words: Dutch: onheil, German: übel, Danish/Norwegian/Swedish: ond/ont, and so on.
Meanwhile the languages in the Latin branch all have words for evil that derive from malus: Spanish/French/Portuguese: mal, Italian: male, and so on, as well as those English words that come from that branch: maleficent, malevolent, malediction, malignant,, and so on.
Long answer short: it's a coincidence. But a fun one, nevertheless.
In Old English dēofol, and yfel, the modern spelling of evil comes from the Kentish dialect (evel), so there is no etymological connection. In Old English, "yfel" had much wider range of meaning, from "bad" to "broken" to "disease"
It is possible that the spelling of the two words influenced each other, by way of a "folk etymology" The spellings had converged by the Middle English period (de[uv]il/ev[ie]l)
Also note that there is no connection between "demon" (a spirit of the air) and "devil" (accuser or slanderer), despite the similar meaning and sound.