“toy with something” = consider an idea or plan.
“I’m toying with the idea of traveling to Europe, but I’m not sure I have enough money.”
“like a kid with a new toy” = very happy with something
“My father is like a kid with a new toy. He can’t stop playing with his new iPhone.”