Double stars are quite common in real life, so double planets are quite common in science fiction.
For example in "Competition" by E.Mayne Hull, Astounding Science Ficiton June 1943 http://www.isfdb.org/cgi-bin/title.cgi?46719 Evana finds that the planet Delfi II has a large moon like companion:
Memory came that the educational talks on the space freighter had proved it wasn't a moon at all, but a dead companion planet as big as Delfi II; and that once, long before man came, there had been life on it--of which obscene remnants remained.
According to Wikipedia, astronomers believe that double planets should exist, but would probably be rather rate.
https://en.wikipedia.org/wiki/Double_planet
The two planets in a double planet would not have to be exactly the same mass to both be habitable for humans.
Stephen H. Dole discussed the requirements for a human habitable planet in Habitable Planets for Man, 1964.
https://www.rand.org/content/dam/rand/pubs/commercial_books/2007/RAND_CB179-1.pdf
Onpages 53 to 58 Dole decided that a human habitable planet would have to have a surface gravity of less than 1.5 g, and thus would have to have a mass of 2.35 Earth mass, a radius of 1.25 Earth radius, and an escape velocity of 15.3 kilometers per second,vor less.
Dole decided that the smallest planet that could retain an oxygen rich atmsphere for geological periods of time would have an escape velocity of 6.25 kilometers per second, and thus a mass of 0.195 Earth mass and a radius of 0.63 Earth radius, and a surface gravity of 0.49 g.
Thus human habitable worlds would have a mass range of 12.05 times and a range of radius of 1.984 times.
But Dole believed that a planet would have to be much more massive than 0.195 Earth mass to produce a breathable oxygen rich atmosphere. Dole decided that a minimum mass of 0.4 Earth mass would be needed, corresponding to a radius of 0.78 Earth radius, and a surface gravity of 0.68 g.
That would give a mass range of 5.785 times, and a radius range of 1.6025 times, between the largest and smallest human habitable worlds.
Whatever the exact figures, a double planet doesn't have to be a twin planet with planets exactly the same size for both of the planets to be habitable for humans. There is a degree of variation in the possible sizes of human habitable planets.
So two worlds which some people might consider to be similar enough in size to count as a double planet, and that other people might consider to be different enough in size to count as a planet and its satellite, might both be within the size range where they could be habitable for humans.
Dole discussed the relationship between a habitable world and its natural satellite(s) on pages 72-75. He discussed the case where a habitable world is a planet and has a natural satellite much smaller than it. He discussed the case where a habitable world is a very large natural satellite or moon orbiting around a much larger planet.
And he discussed the in between case of two planets of similar size orbiting around each other, a double planet.
A planet and its natural satellite will have tidal interactions which slow down their rotation, in some cases slowing down the rotation of a world so much that it becomes tidally locked to the other world, with one side perpetually facing the world.
On page 58 to 61 Dole concluded that days and night that are too long would make a planet uninhabitable for humans. Dole decided that a planet habitable for humans should have a rotation rate that gives one complete rotation longer than 2 or 3 hours and shorter than 96 hours (4 Earth days).
Of course the upper limit of rotation period for a human habitable planet might be longer or shorter than Dole believed.
So a possible planet which was part of a double planet would not be habitable for humans - or lifeforms with similar requirements - if its rotation rate was longer than 96 hours -or hwatever the actual limit is.
Thus a double planet where one or both of the planets have had their rotation periods slowed to take longer than 96 hours, or whatever the real limit is, would be uninhabitable for humans and beings with similar requirements.
So somone designing a ficitonal habitable binary planet would have to calculate that the rotation periods of the two planets would not be slowed down to become longer than the limit for habitabiity.
The PlanetPlanet blog has a section called The ultimate Solar System devoted to designing fictional star systems with as many habitable planets as is scientifically possible.
In the the ulitmate solar system part 5 a system is designed with two binary planets (four planets total) in each orbit in the habitable zone, to squeeze in as many habitable planets as possible.
https://planetplanet.net/2014/05/23/building-the-ultimate-solar-system-part-5-putting-the-pieces-together/
So Sean Raymond, the creator of PlanetPlanet, clearly believes that binary planets can have stable orbits and can be habitable.