The NCAA actually had a short-lived rule where undergrads could enter the draft be drafted but then opt to return to college if they wanted to. They could only use this option once as an undergrad, but it was ultimately killed because NBA teams could hold on to a draftee’s rights until the year after their class was due to graduate.
The only player of significance that I can recall having returned to school under this rule was Voshon Lenard at Minnesota. He was drafted by Milwaukee in the 2nd round and instead of signing a rookie minimum offer of $150K he returned to Minnesota.
The Bucks drafted Shawn Respert the next season and chose to cut Lenard in training camp.
I found a pretty good analysis of this old rule. I don’t expect anything like this to be revisted because of the adverse affects to the player and school.