German police have detained a 26-year-old Tunisian man over links with the perpetrator of an Islamist truck attack on a Berlin Christmas market that killed 12 people, a federal prosecutors' spokeswoman said on Wednesday.