I would say that it is a function if k is given. but when written as y = kx, y is only known if both k and x are known. But whether or not the phrase "k is a constant" is sufficient to determine k and make it a function is just to me semantics. This sort of question is not really about mathematics in my opinion. I.e. if you want to specify a function here, you have to give the value of k. Without it, it does not really matter whether or not you are willing to call it a function, you still don't know its values.
I don't mean to claim a definitive expertise about the "right" answer, I just thought I would illustrate that there are many possible opinions, by expressing a new one. I.e. this question is about how hard it is for people to understand each other, it does not really have a right answer, without more information, but unfortunately is the sort of thing that passes for mathematics in some schools.
mathematics is not about using the "right" words for the objects at hand, it is about doing something with those objects.
forgive me, just an old man's 2 cents. everyone is welcome to have a diferent opinion.
edit: I seem to be getting grumpy in the age of the coronavirus.
Ok, I'll grant that y = kx is a function, but not a real valued function, rather it is a function whose values are multiples of k. Of course we all know that to really specify a function, you have to specify the domain, the range, and a rule that determines exactly one element of the range for each choice of an element of the domain. So within set theory, a function is a triple (S,T,F), where S and T are sets, and F is a subset of SxT, such that no two distinct pairs in F have the same first element. In this sense, technically none of those are functions.