My parents tried that once. My little brother - 3 years old at the time - confessed to something he couldn't possibly have done.
Personally, I've always found this tactic to be particularly unjust and I would never do it. People shouldn't be punished for crimes they didn't commit. Plus, it creates division and strife amongst siblings and encourages tattling.
Well, he did say "old enough for it."
I don't know. I see both sides there. When I was five, I took the blame for something my four-year-old brother did, because we had been grilled and grilled and grilled, relentlessly. Every possible opportunity, we were cornered with "Who did that?" After it went on for two or three days, I was sick of the whole thing, and I thought if I confessed to doing it, that would end the matter. Well, it didn't, because after that the "why did you lie about it" went on and on. "Lie" referred to my initial denial, not to my eventual confession, since they didn't have any way to know that my confession was the actual lie in this situation. They were asking me why I had "lied" by saying I didn't do it. And of course, I had no answer.
Almost ten years passed before my brother finally admitted that he did it. And the only thing he felt, watching me catch it for something he did, was, "Whew. I got away with it." Four-year-olds can be little psychopaths, can't they?
If you already know beyond the shadow of a doubt that the child did something, I'd say don't ask, "Did you do it?" Don't give him/her an opportunity to lie about it. Say, "Because you did this, and I know you did, the consequence is...." But if there is a doubt, I can see where you'd feel horrible if it turns out the child didn't do it. So I would say, only discipline for what you absolutely know the child did.
PS: Even an only child interacts with cousins, neighbors, and classmates. So some of those "he did it, not me" issues can come up.