Germany confirms departure of spy agency chief