The downloadable comprehensive PDF (icao.int) only has one listing for the 747-8.
Compared to the website search function:
My speculation is that the website search accommodates someone searching for "BBJ" in different ways (why, I don't know), or the database needs cleaning up. As you can see, two of the three are the same. And judging by the actual designator, they are all the same.
As for the rules:
They are to be found in ICAO DOC 8643, Aircraft Type Designators; or FAA JO 7360.1B - Aircraft Type Designators. The FAA Job Order is 2 months old and also contains the full list.
The relevant part to this question:
A different designator for an alternate or subtype version of the aircraft will only be allocated when there is a significant difference in performance for ATS or no shared designator can be assigned.
That means the A320neo has significant performance change (A20N vs. A320). A plane like the Boeing 777-200 with three engine options doesn't need different designators. The A330neo is yet to fly, but A339 comes up on the website search. Nothing came up for the A330-800neo.
Related: What will the 737 MAX 7, 8, and 9 ICAO IDs be?
The full rules:
2-2. How Designators are Formulated. The International Civil Aviation Organization (ICAO) has the role
of creating standard aircraft type designators for aircraft that commonly request air traffic service. ICAO
assigns an aircraft type designator using the following principles:
a. Only one designator will be assigned per aircraft type.
b. A designator will be derived from the manufacturer’s model number or name, or from a common
c. The designator will not be longer than four characters and will generally begin with a letter.
d. An assigned designator will not be changed for license-built aircraft, when an aircraft model is sold to
or manufactured by another company, when the manufacturer’s name changes, or when the aircraft type is
derived or converted from another type.
e. A different designator for an alternate or subtype version of the aircraft will only be allocated when
there is a significant difference in performance for ATS or no shared designator can be assigned.
f. “Homebuilt,” “amateur-built,” or “kit plane” aircraft that exist in operationally significant numbers will
be assigned a designator; however, these aircraft will only be listed under the original designer or under the
manufacturer that produces or produced the aircraft type in series.
g. In general, an aircraft type designator will be assigned to all aircraft heavier than micro-/ultra-light. For
the purpose of ICAO Document 8643:
Micro-/ultra-light are those aircraft types with a maximum certified take-off weight of 1,000 pounds
or less and a stall speed not greater than 35 knots.
Micro-/ultra-light helicopters and gyrocopters are those helicopters or gyrocopters with a maximum
certified take-off weight of 1,000 pounds.
Micro-/ultra-light autonomous, optionally piloted, and remotely piloted aircraft are defined as
having a maximum certified take-off weight of 330 pounds or less and a stall speed not greater than 35 knots.
Micro-/ultra-light autonomous, optionally piloted, and remotely piloted helicopters are defined as
having a maximum certified take-off weight of 330 pounds or less.
h. Roman numerals used as part of aircraft model names or numbers will be replaced by Arabic numbers.