Spanish police have searched the home of a missing imam whom they say radicalised the suspects behind the attacks in Barcelona and Cambrils.