Evil comes from man.
The word translated as "evil" in both Isa. 45:7 and 2 Kings 22:20 is Strong's Hebrew 7451: "רָע" or "ra", and means adversity. It is used sometimes as an adjective, and other times as a noun.
Brown-Driver-Briggs (BDB) lists adjectives meaning bad, disagreeable, malignant, unpleasantness, evil days, misery, and unhappiness when speaking of people, diseases, severe judgments, etc. Under nouns, BDB lists evil, injury, distress, misery, and calamity. (Source: here)
The ESV translates Isa. 45:7 as
"I form light and create darkness; I make well-being and create calamity; I am the Lord, who does all these things."
Whereas, the AMP has "creating disaster", the ERV has "I bring peace and I cause trouble", and YLT has "making peace and preparing evil".
In 2 Kings 22:14-20 the prophetess Huldah relayed God's word to King Josiah of the judgment that was going to come upon Judah for their wicked idolatry, and in vs. 16 says,
"Thus said Jehovah, Lo, I am bringing in evil unto this place and on its inhabitants, all the words of the book that the king of Judah hath read," (YLT)
and concludes in vs. 20,
"therefore, lo, I am gathering thee unto thy fathers, and thou hast been gathered unto thy grave in peace, and thine eyes do not look on any of the evil that I am bringing in on this place;' and they bring the king back word." (YLT)
God declared His judgment upon Judah for their idolatry - spiritual fornication against Him - and gave them over to the evil ones of the pagan nations. He wanted Josiah to know that He was staying His judgment until after Josiah's death.
Evil comes from the heart of man (Gen. 8:21; Eccl. 9:3; Matt. 15:18-19; Rom. 7:20).
Jer. 17:9-10,
"9 The heart is deceitful above all things, and desperately wicked: who can know it? 10 I the LORD search the heart, I try the reins, even to give every man according to his ways, and according to the fruit of his doings." (KJV)
When God's cup of indignation and His wrath reaches His limits, then He brings judgment upon the wicked and the evil who have turned away from Him. We are the authors of evil, and when we refuse Him, then He removes His protection and allows wickedness and misery and evil days to overcome us.
Rom. 1: 21-25,
"Because that, when they knew God, they glorified him not as God, neither were thankful; but became vain in their imaginations, and their foolish heart was darkened.
22 Professing themselves to be wise, they became fools,
23 And changed the glory of the uncorruptible God into an image made like to corruptible man, and to birds, and fourfooted beasts, and creeping things.
24 Wherefore God also gave them up to uncleanness through the lusts of their own hearts, to dishonour their own bodies between themselves:
25 Who changed the truth of God into a lie, and worshipped and served the creature more than the Creator, who is blessed for ever. Amen." (KJV)
So, He "creates evil" by bringing in the evil ones to rule over those who will not have Him reign in their hearts. He creates disaster and calamity in the course of pouring out His judgment.
And it was His judgment poured out upon the first born of the Egyptians in Ex. 12:12:
"For I will pass through the land of Egypt this night, and will smite all the firstborn in the land of Egypt, both man and beast; and against all the gods of Egypt I will execute judgment: I am the LORD." (KJV)
He is the Creator, and as the created we are subject to His judgment. He created us for good works (Eph. 2:10) and to show His glory (Isa. 43:7).
Man caused sin to enter this world (Rom. 5:12). We are the ones who continue to create sin, to create evil. God continually has to deal with it, and His long-suffering does have limits. When man's wickedness carried on too long, and they would not turn back to Him, then He would bring in "evil," create calamity, or prepare disagreeable and unpleasant circumstances to punish the wicked.
(Bold emphasis is mine.)