Unless you use options to force a legacy MS-DOS compatible mode, or use expert mode to specify exact LBA block numbers for the beginning and end of partitions, most modern partitioning tools (Linux and otherwise) will align partitions to multiples of 1MB by default. This is also what modern Windows does, and it guarantees compatibility with both 4kB sector size and various SSD and SAN storage devices which might require alignment to larger powers of two for optimal performance.
You can use
lsblk -t to check the alignment offsets of each partition. If the value in the
ALIGNMENT column is zero, then as far as the kernel knows, the partition should be optimally aligned.
To switch the HDD sector size, you would first need to verify that your HDD supports the reconfiguration of the Logical Sector Size. Changing the Logical Sector Size will most likely make all existing data on the disk unusable, requiring you to completely repartition the disk and recreate any filesystems from scratch. The
hdparm --set-sector-size 4096 /dev/sdX would be the "standard" way to change the sector size, but if there's a vendor-specific tool for it, I would generally prefer to use it instead - just in case a particular disk requires vendor-specific special steps.
On NVMe SSDs,
nvme id-ns -H /dev/nvmeXnY will tell (among other things) the sector size(s) supported by the SDD, the LBA Format number associated with each sector size, and the currently-used sector size. If you wish to change the sector size, and the desired size is actually supported, you can use
nvme format --lbaf=<number> /dev/nvmeXnY to reformat a particular NVMe namespace to a different sector size.