wow i cant believe gyro mazda let you drive another customers car... from the way you describe you need a idle valve its a valve that stays open when you take your foot off the gas to supply air to the engine for idle... id pay $150 for a service at rustcheck its called intake cleaner they run chemicals thru your engine to clean it restores power. also check your EGR valve and air filter...