If you place a bed with a command, except for a color data tag, a red bed is placed.
/setblock ~ ~ ~ bed default replace {color:1}
→ orange bed (work properly)
No NBT
/setblock ~ ~ ~ bed
→ red bed
No tags
/setblock ~ ~ ~ bed default replace {}
→ red bed
color tag without value
/setblock ~ ~ ~ bed default replace {color:}
→ white bed
Any other tag
/setblock ~ ~ ~ bed default replace {test:1}
→ red bed