Nothing in RAW prevents this, but ...
... the DM isn't required to have them roll again.
Let's get back to basics. From Basic Rules Chapter 1: (I added formatting for clarity)
The DM describes the environment.
The players describe what they want to do.
- {snip} ...the DM listens to every player and decides how to resolve those actions.
- Sometimes, resolving a task is easy. If an adventurer wants to walk across a room and open a door, the DM might just say that the
door opens and describe what lies beyond. But the door might be
locked, the floor might hide a deadly trap, or some other
circumstance might make it challenging for an adventurer to complete a
task. In those cases, the DM decides what happens, often relying on
the roll of a die to determine the results of an action.
- The DM narrates the results of the adventurers’ actions.
Unlike some versions of D&D where the player triggers/initiates the ability/skill check, in D&D 5e the DM is the one who calls for the die roll, or does not.
Ability Checks(Chapter 7: Using Ability Scores)
The DM calls for an ability check when a character or monster attempts
an action (other than an attack) that has a chance of failure. When
the outcome is uncertain, the dice determine the results.
In the above case, there was already a failure. If the DM is not given additional input from the PC on "what would be different about this second attempt at search" there is no compelling reason to roll again. But they can also allow that.
- As an example, it may be useful to allow that if the DM is using a 'ticking clock' kind of session where the players have to achieve "X" before event "Y" happens. At this point, the choice to "search again" or not has a consequence, but that consequence may or may not have nothing to do with finding anything in the room.
If the DM feels that another circumstance has influenced the room's condition, or the players perception (I put on my dark vision goggles!) to warrant a reassessment of the chance of success of failure, then a DM calling for the player to roll another check would make sense.
Sometimes a character fails an ability check and wants to try again.
In some cases, a character is free to do so; the only real cost is the
time it takes. (DMG p. 237)
The DMG (p. 237) has additional guidance for DM's to apply, at their discretion, regarding adjudicating ability checks.
When a player wants to do something, it's often appropriate to let the
attempt succeed {or fail is implied if not stated} without a roll or a reference to the character's ability scores. For example, a character doesn't normally need to make a Dexterity check to walk across an empty room or a Charisma check to order a mug of ale. Only call for a roll if there is a meaningful consequence for failure.
When deciding whether to use a roll, ask yourself two questions:
- Is a task so easy and so free of conflict and stress that there
should be no chance of failure?
- Is a task so inappropriate or impossible- such as hitting the moon
with an arrow-that it can't work?
If the answer to both of these questions is no, some kind of roll is appropriate.
There is some good advice in this Q&A here on multiple ability checks in general.