A traditional hand-held hammer consists of a separate head and a handle, fastened together by means of a special wedge made for the purpose, or by glue, or both.
A loose hammer head is hazardous because it can literally "fly off the handle" when in use, becoming a dangerous uncontrolled missile.