A detention is when the person who's stopped by the police is not free to leave. The police can detain you if they have a reasonable suspicion that you've been involved in some type of criminal activity. They can't arrest you because they don't yet have proper cause, they have to do further investigation. The difference essentially is that detention means that you're not free to leave. Obviously when you're arrested, you're in handcuffs and you're going to jail.