The spikes are caused by diffraction of light around the struts supporting the secondary mirror. Hubble has 4 supports for the secondary mirror. JWST has 3 support for the secondary mirror, which because...physics (I don't know I'm not an optics guy)...manifests as 6 diffraction lines.
https://en.wikipedia.org/wiki/Diffraction_spike
EDIT: It may be caused by both the diffraction spikes from the supports struts and the shape of the mirror and aperture. I'm not really sure. The JWST images also seem to have two additional small spikes that look more like the diffraction pattern from a single strut, which could also be a support strut for a stop further down the optics chain.