One in five used cars in the UK has a damage history, new research shows.