The best thing you can do is find him a new friend quickly. The reason why he's acting like this is because he doesn't know where his friend is. He might believe that his friend got lost and you can't find him. He likely doesn't know that his friend has passed, which is why he's frantically searching for his friend. Now, there is one way to prevent this behavior, but it's quite grusome...after the Ratty friend passes away, you need to let your current boy see his friend before taking him away. Rats are incredibly intelligent creatures, and they know when a friend has passed. They'll do sort of a ritual of sniffing his mouth and licking his friend, which scientists and ratty caretakers think is a sign of searching for any signs of life. After they'rw convinced that their friend is gone, they'll slowly walk away and sometimes look back at their beloved friend. Luckily, Rats usually let their friends who have passed on go fairly quickly. I am so sorry for your loss and I hope this helped!