Den tyska förbundsdagen har antagit ett förslag om att införa tuffare regler för invandring.