This same misunderstanding shows up in Acts:
A man named Simon used to practice magic in the city and astounded the people of Samaria, claiming to be someone great.All of them, from the least to the greatest, paid attention to him, saying, “This man is the ‘Power of God’ that is called ‘Great.’ They paid attention to him because he had astounded them by his magic for a long time, but once they began to believe Philip as he preached the good news about the kingdom of God and the name of Jesus Christ, men and women alike were baptized. Even Simon himself believed and, after being baptized, became devoted to Philip; and when he saw the signs and mighty deeds that were occurring, he was astounded.
Now when the apostles in Jerusalem heard that Samaria had accepted the word of God, they sent them Peter and John, who went down and prayed for them, that they might receive the holy Spirit, for it had not yet fallen upon any of them; they had only been baptized in the name of the Lord Jesus. Then they laid hands on them and they received the holy Spirit.
When Simon saw that the Spirit was conferred by the laying on of the apostles’ hands, he offered them money and said, “Give me this power too, so that anyone upon whom I lay my hands may receive the holy Spirit.” But Peter said to him, “May your money perish with you, because you thought that you could buy the gift of God with money. You have no share or lot in this matter, for your heart is not upright before God. Repent of this wickedness of yours and pray to the Lord that, if possible, your intention may be forgiven. For I see that you are filled with bitter gall and are in the bonds of iniquity. 4Simon said in reply, “Pray for me to the Lord, that nothing of what you have said may come upon me.” So when they had testified and proclaimed the word of the Lord, they returned to Jerusalem and preached the good news to many Samaritan villages.
Acts 8:9-25
Then some itinerant Jewish exorcists tried to invoke the name of the Lord Jesus over those with evil spirits, saying, “I adjure you by the Jesus whom Paul preaches.” When the seven sons of Sceva, a Jewish high priest, tried to do this, the evil spirit said to them in reply, “Jesus I recognize, Paul I know, but who are you?” The person with the evil spirit then sprang at them and subdued them all. He so overpowered them that they fled naked and wounded from that house. When this became known to all the Jews and Greeks who lived in Ephesus, fear fell upon them all, and the name of the Lord Jesus was held in great esteem.
Many of those who had become believers came forward and openly acknowledged their former practices. Moreover, a large number of those who had practiced magic collected their books and burned them in public. They calculated their value and found it to be fifty thousand silver pieces. Thus did the word of the Lord continue to spread with influence and power.
Acts 19:19
Practicing magic is clearly not compatible with Christianity. A plain reading of the New Testament shows this; it is associated with possession by demons, actually.