You are correct. In the straight chain form, it has four stereogenic carbons (2, 3, 4, and 5). But when it forms a ring, the carbonyl can be attacked from top or bottom, forming a new chiral center at C1. Hence, the alpha and beta anomers are formed.