This question highlights the importance of considering the whole of Scripture rather than cutting and pasting one or two verses to resolve a theological dilemma.
Although two specific verses in a few translations record Jesus emphasizing prayer and fasting (Matthew 17:21 and Mark 9:29), many Bible scholars insist these verses should be regarded as erroneous (or at least extraneous) because New Testament manuscripts now considered to be more accurate don't depict our Redeemer saying that certain prayers won't be answered if our tummies aren't growling.
While fasting is an important part of discipleship (after all, Jesus fasted 40 days before he began his public ministry), Jesus actually warns about the potential dangers associated with fasting more often than he endorses the activity.
What Does God Say About This?
When some men asked Jesus why his disciples didn't fast, our Savior equated fasting with sorrow and essentially said his boys wouldn't mourn until he left the proverbial building: "Can you make wedding guests fast while the bridegroom is with them?" (Luke 5:34, esv). In the Sermon on the Mount, Jesus cautions people about distorting the private discipline of fasting to get a public pat on the back: "And when you fast, do not look gloomy like the hypocrites, for they disfigure their faces that their fasting may be seen by others. Truly, I say to you, they have received their reward. But when you fast, anoint your head and wash your face, that your fasting may not be seen by others but by your Father who is in secret. And your Father who sees in secret will reward you" (Matthew 6:16-18, esv).