I want my game to support phones with max texture size of 1024 so my texture atlases are 1024. My question is: are lightmaps also considered textures and their max size must be 1024? Or they can have higher dimensions like 4096?
Yes, lightmaps are textures. Lightmaps are a record of the lighting value for a surface at a particular point, and the way we represent "surface data for a particular point" in modern 3D graphics is with textures.
Unity's lightmapping implementation uses Beast. The default lightmap atlas size limit is 1024x1024. Terrain, per the documentation, allows you to specify an arbitrary lightmap size. The documentation does not mention a limit, but this thread suggests the limit is 4096x4096.
That thread also notes that you can chance the size of regular lightmap atlas textures via scripting, by setting
LightmapEditorSettings.maxAtlasHeight to any value up to 4096.
However, if you are self-imposing a limit of 1024x1024 for your textures you will not want to exceed that in the setting of any lightmap sizes, because that will cause the creation of larger textures.