Cockatoos are very funny birds. They have really high intelligence levels and can mimic sounds like crazy too. Search online for Cockatoos talking and you'll be surprised how good they can get at it.
They mimic sounds like doorbells, cell phones and car alarms. The strangest mimicry I have ever heard a cockatoo perform is barking like a dog.
When I watched the video I was confused because I thought there was a dog outside backing at the cockatoo, but then after reading the caption and watching the bird, I realized it is the cockatoo doing that.
Cockatoos also like to socialize and so they want to be part of a family. With this one being around a dog all the time and hear dog barking it's obviously thinks that barking is a form of communication that the dog uses. So it is not just the ability to mimic sound but also to mimic energy which you see it doing when it's bobbing the head and doing the entire act of barking. It's doing it with complete conviction that it means something.
One of the amazing things is the length they will go to to sound very similar to what they mimic. You might think it's funny until the cockatoo thinks that barking at 6:00 am is an appropriate time.
I have watched videos of cockatoos picking up different sounds like laughter, sneezing and the words the owner was using in an argument. All of this shows how adaptable animals like these can become.