You will have to trace and cut the wiring to the beacon and connect it to the blue and yellow wires of the decoder, provided you're not already using the yellow wire for a backup light.
The DH123D is a 2 function decoder; i.e., headlight and backup light, so if you're using the yellow wire for a backup light, you will have to change the decoder to a different type, such as the DH163, so you'll have a function available for the beacon. The beacon is probably an LED, which is polarity sensitive and will also require a 1K Ohm resistor. It will not light up if you get the wires backwards.
Then refer to pages 35 and 36 of the Digitrax Mobile Decoder Manual, which can be downloaded from their web site, on CV changes to make the light flash.
I just recently put Digitrax decoders model number DH123D in a new Athearen SD-45 and a GP-40X. I discovered that both of these locomotives have a light bulb in the Lighting Beacon, This light bulb is also connected to the head light. I would like to know how can I make just the lighting beacon flash or appear to be rotating without having the head light do the same.