Tuning the Kondo and Fano effects in double quantum dots