Is it possible for an airplane to fly as it compress the atmospheric air during flight?
First of all, where does the compressed air come from? Is it stored in big tanks, or do you compress it as you fly?
Assuming you use the second way (the first would be quite inefficient), you need to power the Air Compressor, which means you need to generate energy.
If you do not want to use fuel, then it has to be powered by electricity, i.e. an electric plane. This is basically how the Airbus E-Fan works, using two ducted fans powered by electricity (as @Zach Lipton said in the comments)
So to answer your question, yes, your theory works. There are already a few prototypes using it.