I made an animation in other blend file (with keyframes). Now when I imported it into a new file, the animation has one of these dots per frame intead a keyframe inserted.
Why does this happen? I added an ordinary keyframe to compare.
These appear to be Moving Hold keyframes. From the Blender Manual:
Moving Hold (slight orange diamond)
A keyframe that adds a small amount of motion around a holding pose. In the Dope Sheet it will also draw a bar between them.
These keyframes are intended to add small bits of motion in between more major keyframes so that characters in a single position don't look like statues. Since they don't signify major movements, the DopeSheet draws lines through them when connecting identical keyframes.
Moving Hold keyframes can be added by changing the New Keyframe Type in the timeline:
Since the icons for Moving Hold and standard keyframes are very similar (the Moving Hold icon is slightly smaller and a little bit orange), it appears that you accidentally selected Moving Hold instead of Keyframe before animating.
This won't affect the animation; the different keyframe types are just to help you keep your animation organized.