Example: I read a red spellbook, it crumbles and blinds me. It then asks me what to call it. What's the point of this? What am I supposed to do? I've read the NetHackWiki on the naming article but I don't understand what the hell it's used for. Thanks in advance.
The point of naming is for you to make notes for yourself in the future - you can name that spellbook "book of blinding" and the next time you find one it'll be labeled "book of blinding" instead of just "red spellbook".
The game will remember your notes about these objects instead of you having to keep notes manually on what is what.
Now, these notes are only valid for the particular game you're playing now so if it's one that ends your game there's not much purpose to it. But many times you'll drink a potion or read a spellbook, get a non-fatal effect, and you can then name the item to remember that effect for next time.
You could name it "red, crumbled when I read it at character level 5". This way the next time you see a red spellbook, you'll remember that the last time you read one of those, it crumbled to dust (which tells you something about which level the spell is - unless the spellbook was cursed, but you should check that before reading it).
Basically every time an item is destroyed in a way which gives you some information that you could use to identify it, you'll have a chance to name it so you don't have to keep notes manually.