By design, not a bug. You also cannot put laser sights on rifles or crossbows, foregrips on rifles or crossbows, and there's two different extended magazine items for pistol/smg and rifles respectively.
I'm more annoyed that you can't put laser sights on energy or chemical pistols(they have optional attachment slots, but you can't put anything in them, no compatible attachments).