Children on the beach with their dog.
The children are at the ocean with their dog.
Being at the beach implies there is a body of water, such as the ocean.
"Children at the ocean" is rephrasing "children are at the beach".
The beach is next to the ocean and the children are there with their dog.