Function 0Bh comes from the CGA, whose colour select register controlled three things at once, and the EGA and VGA BIOSes keep its meaning. With BH = 0, BL is a colour 0–15: in text modes it sets the border, the overscan area around the text; in CGA graphics it sets the background, colour 0, together with the border. With BH = 1, BL chooses between the CGA's two sets of colours 1–3 for 320×200 graphics:

PaletteColour 1Colour 2Colour 3
0greenredbrown
1cyanmagentalight grey / white

Each palette also exists in a bright version, chosen on the CGA by an intensity bit that goes with the background colour. Mode 04h starts with palette 1. Here three bars are drawn in colours 1, 2 and 3 on a blue background, then the palette is switched under them:

Prints "Palette 1, then palette 0"; on the screen three bars on a blue background for a second, which then change colour as palette 0 replaces palette 1; after another second the text screen comes back cleared.
MOV AX, 0004h ; mode 04h: CGA 320x200, 4 colours
INT 10h
MOV AH, 0Bh
MOV BX, 0001h ; BH = 0: background; BL = 1: blue
INT 10h
MOV AH, 0Bh
MOV BX, 0101h ; BH = 1: palette; BL = 1
INT 10h
MOV BX, 0001h ; BH = page 0, BL = colour of the first bar
MOV DX, 70 ; first row
BAND1:
MOV SI, 10 ; 10 rows per bar
LINE1:
MOV CX, 80 ; x from 80 to 239
DOT1:
MOV AH, 0Ch ; write a pixel: AL = colour, CX = x, DX = y
MOV AL, BL
INT 10h
INC CX
CMP CX, 240
JB DOT1
INC DX
DEC SI
JNZ LINE1
ADD DX, 10 ; a gap of 10 rows
INC BL ; the next colour
CMP BL, 4
JB BAND1
CALL WAIT1 ; a second with palette 1
MOV AH, 0Bh
MOV BX, 0100h ; BH = 1, BL = 0: palette 0
INT 10h
CALL WAIT1 ; a second with palette 0
MOV AX, 0003h ; mode 03h again: 80x25 text, clears the screen
INT 10h
MOV AH, 09h
MOV DX, OFFSET MSG1
INT 21h
MSG1 DB "Palette 1, then palette 0", 13, 10, "$"
WAIT1: ; wait 1 s: CX:DX = 0F4240h microseconds
MOV CX, 000Fh
MOV DX, 4240h
MOV AH, 86h
INT 15h
RET

Nothing is redrawn when the palette changes: the pixels still hold the numbers 1, 2 and 3, and only their meaning changes. That is why the switch is instant.

On EGA and VGA

The general way to change colours on these cards is INT 10h AH=10h, the palette registers and the DAC; 0Bh remains for the CGA modes and the border. In the 16-colour EGA and VGA graphics modes, BH = 0 sets the background colour. The text-mode border is a narrow strip on a VGA, and many monitors and emulators show little or nothing of it, depending on their settings.