This varies between fields a lot. In economics, I haven't seen many cases of e.g. thesis advisors rubberstamping their name on to someone else's work - not that it doesn't happen, but it is rare, and it would get you a bad rep if it became visible. In other fields I've interacted with, it seems quite standard for the lab leader or chair to get their name on every paper of the lab, and for papers to be padded with authors who did not contribute that much.