MessageBuilder avoids intermediate HashMap for MessageHeaders building

Issue: SPR-11468
Polishing