5 hours once or twice a week is a pretty good deal for the dog. Many, many dog owners regularly leave their dogs home for 8 hours while they are away at work. Very few people would own dogs if they couldn't leave them at home during a work day!
When you get your new puppy, start separation training and crate training very early to teach the pup that being left alone is not a bad thing. You can search "Separation Training" or "Crate games" on this forum and find some reading material.
It also helps if you can find a good breeder who can tell you all about the personalities of their lines. If their lines tend to dislike separation and cry a lot...then that may not be the breeder for you. If the breeder can tell you that the pup's parents are fine being left alone, and that ancestors and siblings or half-siblings have successfully integrated into homes that work away from home, then that will likely be a good choice. Ideally, the breeder will have started introducing the pups to the crate, as well.
If you need help finding a good breeder, the forum is always happy to help. Because Maltese are cute little dogs, there are many backyard breeders and puppy mills who sell these dogs for top dollar, but they have not done any of the titling, health testing, and careful research that top notch breeders with temperamentally and physically sound puppies complete.