Those layers are not set directly as attributes of self, so you need to register them explicitly using self.add_module(namestr, layer). For example…
class MLP(nn.Module):
    def __init__(self, h_sizes, out_size):
        ...
        for k in range(len(h_sizes)-1):
            self.hidden.append(nn.Linear(h_sizes[k], h_sizes[k+1]))
            self.add_module("hidden_layer"+str(k), self.hidden[-1])
        ...

Using nn.ModuleList is a much neater solution.
class MLP(nn.Module):
    def __init__(self, h_sizes, out_size):
        ...
        self.hidden = nn.ModuleList()
        for k in range(len(h_sizes)-1):
            self.hidden.append(nn.Linear(h_sizes[k], h_sizes[k+1]))
        ...